Both short integer and integer in C account for 2 bytes, and the range of values is -32768 ~ ~ 32767.
Long integers account for 4 bytes, and the range of values is-2147483648 ~ ~ 2147483647.
If it is an unsigned number, the data that can be represented is
Short integers and integers: 0-65535
Long integer: 0-4294967295
In C language, if a large number exceeds the maximum length integer, it can be stored by double, which will not affect the operation accuracy.
2. Different types of data have different ranges:
[Signature ]int :-32768-32767
Unsigned integer: 0-65535
[signature ]short[int]:-32767-32768
long[int]:-2^3 1-(2^3 1- 1)
Unsigned long integer [int]: 0-(2 32-1)
float: 10^-37 - 10^38
double: 10^-307- 10^308
Long double:10-4931-10 4932