The method for putting printable characters in character and string constants is straightforward: 'A' or "Hello".
A different method is needed for nonprintable characters.
The most commonly used nonprintable characters can be expressed as a 2-character escape sequence. These escape sequences will work for any character encoding (ASCII, EBCDIC, etc).
'\a' alert (that is, BELL)
'\b' backspace
'\f' form feed
'\n' newline
'\r' carriage return
'\t' horizontal tab
'\v' vertical tab
'\\' backslash
'\'' single quote
'\"' double quote
'\?' question mark
Another way to specify characters is with a numeric escape code. However, the numeric values will depend on the character encoding.
\025 Octal value 25 (decimal 21)
\x15 Hexadecimal value 0x15 (decimal 21)