Rules for Standard Type Sizes

In ANSI-C, enu merations have the type of int. In this implementation they must be smaller than or equal to int. The following listing lists the size rules for integer types.

Listing: Size Relationships among Integer Types
sizeof(char)   <= sizeof(short)
sizeof(short)  <= sizeof(int)

sizeof(int)    <= sizeof(long)

sizeof(long)   <= sizeof(long long)

sizeof(float)  <= sizeof(double)

sizeof(double) <= sizeof(long double)