/* 整数型の大きさと範囲 */ #include #include int main(void) { printf(" char:%3lu byte %d 〜 %d\n", sizeof(char),CHAR_MIN,CHAR_MAX); printf(" short:%3lu bytes %d 〜 %d\n", sizeof(short),SHRT_MIN,SHRT_MAX); printf(" int:%3lu bytes %d 〜 %d\n", sizeof(int),INT_MIN,INT_MAX); printf(" long:%3lu bytes %ld 〜 %ld\n", sizeof(long),LONG_MIN,LONG_MAX); printf("long long:%3lu bytes %lld 〜 %lld\n", sizeof(long long),LLONG_MIN,LLONG_MAX); return 0; }