Character Set in ‘C’. The set of characters that may appear in a legal ‘C’ program is called the character set for ‘C’. These include some graphics as well as non-graphic characters. The ‘C’ character set consists of upper case and lower case alphabets, special characters, digits and white spaces. The alphabets and digits together are called the alphanumeric characters.
Alphabets
A, B, C, ………, Y, Z.
a, b, c, ………, y, z.
‘C’ is case sensitive language, it means lower and upper case are different.
Digits 0, 1, 2, 3, 4, 5, 6, 7, 8, 9.
Special Characters
- , → Comma
- % → Percent sign
- . → Period
- ? → Question mark
- ; → Semicolon
- & → Ampersand
- : → Colon
- ^ → Caret
- # → Number sign (Hash)
- * → Asterisk
- ‘ → Apostrophe
- – → Minus sign
- ” → Quotation mark
- + → Plus sign
- ! → Exclamation mark
- / → Slash
- | → Vertical bar
- \ → Backslash
- ~ → Tilde
- < → Opening angle bracket
- > → Closing angle bracket
- _ → Underscore
- $ → Dollar sign
- ( → Left parenthesis
- ) → Right parenthesis
- [ → Left bracket
- ] → Right bracket
- { → left brace
- } → Right brace