type in C/C++ and Fortran2008 | bits | range |
int/INTEGER (2) | 16 | -32768 to 32767 |
unsigned int | 16 | 0 to 65535 |
signed int | 16 | -32768 to 32767 |
short int | 16 | -32768 to 32767 |
unsigned short int | 16 | 0 to 65535 |
signed short int | 16 | \( -32768 \) to 32767 |
int/long int/INTEGER (4) | 32 | -2147483648 to 2147483647 |
signed long int | 32 | -2147483648 to 2147483647 |
float/REAL(4) | 32 | \( 3.4\times 10^{-44} \) to \( 3.4\times 10^{+38} \) |
double/REAL(8) | 64 | \( 1.7\times 10^{-322} \) to \( 1.7\times 10^{+308} \) |
long double | 64 | \( 1.7\times 10^{-322} \) to \( 1.7\times 10^{+308} \) |