Character Set In C Programming Language





The C character set, also known as the ASCII character set, is a set of characters that can be used in the C programming language. The term "ASCII" stands for American Standard Code for Information Interchange. Originally developed in the 1960s, ASCII is a widely used character encoding standard that defines numeric codes for various characters.


In the C character set, the basic set of characters consists of 128 characters, including:

Table of content For Character Set
The uppercase lettersA to Z (65 to 90)
The lowercase lettersa to z (97 to 122)
The decimal digits 0 to 9 (48 to 57)
Special characters punctuation marks, spaces, and mathematical symbols
Control charactersnewline, carriage return, and tab


The ASCII character set is a subset of the Unicode character set, which is a more comprehensive character encoding standard that supports characters from various languages and scripts worldwide. However, for compatibility and historical reasons, the C programming language still primarily relies on the ASCII character set.

In addition to the basic ASCII characters, the C language also defines escape sequences that represent special characters using backslash () followed by a specific character. For example, '\n' represents a newline character, '\t' represents a tab character, and '\' represents a backslash character.

It's worth noting that the C character set has been extended to include additional characters beyond the original ASCII set. This extension is known as the "extended character set" and includes characters with numeric codes greater than 127. The exact set of extended characters may vary depending on the implementation and locale settings of the C programming environment.