Run ❯
Get your
own
website
×
Change Orientation
Change Theme, Dark/Light
Go to Spaces
#include
int main() { int myInt = 4294967292; unsigned int myUInt = 4294967292; short int mySInt = 65532; unsigned short int myUSInt = 65532; long int myLInt = 18446744073709551612; unsigned long int myULInt = 18446744073709551612; printf("size: %zu bits value: %d\n", 8*sizeof(myInt), myInt); printf("size: %zu bits value: %u\n", 8*sizeof(myUInt), myUInt); printf("size: %zu bits value: %d\n", 8*sizeof(mySInt), mySInt); printf("size: %zu bits value: %u\n", 8*sizeof(myUSInt), myUSInt); printf("size: %zu bits value: %lld\n", 8*sizeof(myLInt), myLInt); printf("size: %zu bits value: %llu\n", 8*sizeof(myULInt), myULInt); return 0; }
size: 32 bits value: -4
size: 32 bits value: 4294967292
size: 16 bits value: -4
size: 16 bits value: 65532
size: 64 bits value: -4
size: 64 bits value: 18446744073709551612