Translate

Labels

Friday, 21 December 2012

DATA TYPES AND THEIR RANGE


                                                                                                     2^(X-1)  to  2^(x-1)-1
TYPE
LENGTH
RANGE
Unsigned char
8 bits-> 1 byte
0 to 255
char
8 bits-> 1 byte
-128 to 127
enum
16 bits->2 byte
-32,768 to 32,767
Unsigned int
16 bits-> 2byte
0 to 65,535
Short int
16 bits-> 2 byte
-32,768 to 32,767
int
16 bits-> 2 byte
-32,768 to 32,767
Unsigned long
32 bits->4 byte
0 to 4,294,967,295
long
32 bits->4 byte
-2,147,483,648 to 2,147,483,647
float
32 bits-> 4 byte
3.4*(10**-38) to 3.4*(10**+38)
double
64 bits-> 8 byte
1.7*(10**-308) to 1.7*(10**+308)
Long double
80 bits-> 10 byte
3.4*(10**-4932) to 1.1*(10**+4932)



                                                                                       x->bits

No comments: