DATA TYPE
Definition
- It is a type of data which is used in the program.
- There are many predefined data types inc library like int, char, float, etc.
Basic Type |
Integer Type(int) |
Floating Type(float) |
|
Character Type(char) |
|
Derived
Type |
Pointer |
Array |
|
Structure |
|
Union |
Data Type |
Size in bytes |
Range |
short |
2 |
-32768 to +32767 |
int |
2 |
-32768 to +32767 |
unsigned int |
2 |
0 to 65536 |
long |
4 |
-2147483648 to +2147483647 |
unsigned long int |
4 |
0 to 4,294,967,295 |
Float Type
Data Type |
Size in bytes |
Range |
float |
4 |
3.4E-38 to 3.4E+38 |
double |
8 |
1.7E-308 to 1.7E+308 |
long double |
10 |
3.4E-4932 to 1.1E+4932 |
Character Type
Data Type |
Size in bytes |
Range |
char |
1 |
-128 to +127 |
signed char |
1 |
-128 to -127 |
unsigned char |
1 |
0 to 255 |