Home > Article > Backend Development > List escape characters in C#
The following is the list of escape characters in C# -
Escape Characters | Description th> | Pattern |
---|---|---|
\a | Matches the bell character \u0007. | \a |
\b | In character class, matches the backspace key \u0008. | [\b]{ 3,} |
\t | matches tab character,\u0009. | (\w )\t |
\r | Match the carriage return character \u000D. (\r is not equal to the newline character .) |
\r (\w ) |
\v | Match vertical tab character \u000B. | [\v]{2,} |
\f | matches the form feed character, \u000C. | [\f]{2,} |
Matches new line \u000A. | \r (\w ) |
|
matches the escape character \u001B. | \e | |
nn |
Use octal representation to specify characters (nnn consists of up to three digits). | \w\040\w |
\ x nn | Use hexadecimal representation to specify characters (nn consists of only two digits ). | \w\x20\w |
Matches the ASCII control character specified by X or x, where X or x is Control character alphabet. | \cC td> | |
\u nnnn | Matches Unicode characters using the hexadecimal representation (exactly four digits, as represented by nnnn). | \w \u0020\w |
\ | Matches a character when followed by a character that is not recognized as an escape character. | \d [\ -x\*]\d \d [\ -x\*\d |
The above is the detailed content of List escape characters in C#. For more information, please follow other related articles on the PHP Chinese website!