A sequence of keystrokes or output characters that begins with the ESC character. Escape sequences are typically used for positioning the cursor and controlling the display of text on the screen, or as codes to control printers.