C language character set

C character set: In this tutorial, we are going to learn about the character set in C programming language, the valid characters allowed in C language.
Submitted by IncludeHelp, on July 29, 2019

Every language has the set of the characters which are used to form a sentence to write a program/code, we cannot use any character except the valid set of the characters defined by the programming language.

C character set

Similarly, C programming language also has a set of characters, which are used to form a C language statement.

C programming language character set contains the following characters i.e. following are the valid character set in C programming language,

  1. Alphabets
  2. Digits
  3. Special Characters

1) Alphabets

C programming supports all the uppercase and lowercase alphabets.

    Uppercase alphabets: 
    A, B, C, D, E, F, G, H, I, J, K, L, M, N, 
    O, P, Q, R, S, T, U, V, W, X, Y, Z
    Lowercase alphabets: 
    a, b, c, d, e, f, g, h, i, j, k, l, m, n, 
    o, p, q, r, s, t, u, v, w, x, y, z

So, there are total of 52 alphabets (all uppercase and lowercase) are allowed in C programming language.

2) Digits

C programming supports all digits from 0 to 9, which are used to represent/construct a numeric value/expression or digits can also be used to define an identifier.

    Digits: 0, 1, 2, 3, 4, 5, 6, 7, 8, 9

So, there are total 10 digits (all digits) are allowed in C programming language.

3) Special characters

There are some of the special characters, which are used for special purposes (like mathematical, logical operations, etc), or to define an identifier in a batter way (like underscore to construct a long variable name, etc).

In C programming language, there are following special characters:

    ~ ` ! @ # $ % ^ & * ( ) _ - + = | \ { } [ ] : ; “ ‘ < > , . ? /  

C language characters set table

Here is the table contains all C language character set,

Table format:

Alphabets A, B, C, D, E, F, G, H, I, J, K, L, M, N, O, P, Q, R, S, T, U, V, W, X, Y, Z
a, b, c, d, e, f, g, h, i, j, k, l, m, n, o, p, q, r, s, t, u, v, w, x, y, z
Digits 0, 1, 2, 3, 4, 5, 6, 7, 8, 9
Special characters ~ ` ! @ # $ % ^ & * ( ) _ - + = | \ { } [ ] : ; “ ‘ < > , . ? /

Image format:

C language characters set table

C Language Tutorial »






Comments and Discussions!

Load comments ↻






Copyright © 2024 www.includehelp.com. All rights reserved.