A short is at least 16 bits and a long is at least 32 bits, so what's the point of an int which can be either 16-bit or 32-bit?
PS: I'm talking about ANSI C here.
A short is at least 16 bits and a long is at least 32 bits, so what's the point of an int which can be either 16-bit or 32-bit?
PS: I'm talking about ANSI C here.
short, int and long are by definition three different Type specifiers, where, short int ranks lower than int which ranks lower than long int.
C standard only specifies the minimum (and comparative, for example, int cannot be wider than long) requirements, an implementation may choose to provide any other wider definition of the types, keeping the constraints alive.