Tip

C# Character Escape Sequences

  1. \' – single quote, needed for character literals
  2. \" – double quote, needed for string literals
  3. \\ – backslash
  4. \0 – Unicode character 0
  5. \a – Alert (character 7)
  6. \b – Backspace (character 8)
  7. \f – Form feed (character 12)
  8. \n – New line (character 10)
  9. \r – Carriage return (character 13)
  10. \t – Horizontal tab (character 9)
  11. \v – Vertical quote (character 11)
  12. \uxxxx – Unicode escape sequence for character with hex value xxxx
  13. \xn[n][n][n] – Unicode escape sequence for character with hex value nnnn (variable length version of \uxxxx)
  14. \Uxxxxxxxx – Unicode escape sequence for character with hex value xxxxxxxx (for generating surrogates)
Posts created 141

Leave a Reply

Related Posts

Begin typing your search term above and press enter to search. Press ESC to cancel.

Back To Top