Integer data type storage allocations : Integer Family « Data Type « C Tutorial






Data TypeAllocationRange
signed char1 byte-2^7 to 2^7-1(-128 to 127)
Unsigned char1 byte0 to 2^8-1(0 to 255)
short2 bytes-2^15 to 2^15 -1 (-32768 to 32767)
Unsigned short2 bytes0 to 216 -1 (0 to 65535)
long int4 bytes2^31 to 2^31-1 (2,147,483,648 to 2,147,483,647)
int2 or 4 bytes depending on implementation


2.7.Integer Family
2.7.1.Integer family
2.7.2.Float family (real numbers with decimal points)
2.7.3.Integer data type storage allocations
2.7.4.Using the integer conversion specifiers
2.7.5.Printing an unsigned integer in bits