For octal notation, the backslash conventions require three characters when the next character could be confused with the octal number.
For hexadecimal notation, the backslash conventions require two characters when the next character could be confused with the hexadecimal number.
|
|
Convention |
Meaning |
\a |
Alert (0x07) |
\b |
Backspace (0x08) |
\f |
Form feed (0x0c) |
\n |
Newline (0x0a) |
\r |
Carriage return (0x0d) |
\t |
Horizontal tab (0x09) |
\v |
Vertical feed (0x0b) |
\\ |
Backslash (0x5c) |
\" |
Quotation mark (0x22) |
\' |
Single quote (0x27) |
\000 |
Character whose octal value is 000 |
\Xnn |
Character whose hexadecimal value is nn |
|