반응형
#include <iostream> int main() { std::cout << "1 char=" << sizeof(char) << std::endl; std::cout << "2 unsigned char=" << sizeof(unsigned char) << std::endl; std::cout << "3 int=" << sizeof(int) << std::endl; std::cout << "4 unsigned int=" << sizeof(unsigned int) << std::endl; std::cout << "5 long=" << sizeof(long) << std::endl; std::cout << "6 unsigned long=" << sizeof(unsigned long) << std::endl; std::cout << "7 float=" << sizeof(float) << std::endl; std::cout << "8 double=" << sizeof(double) << std::endl; std::cout << "9 long double=" << sizeof(long double) << std::endl; std::cout << "10 long long=" << sizeof(long long) << std::endl; std::cout << "11 unsigned long double=" << sizeof(unsigned long long) << std::endl; return 0; } | cs |
반응형
'C,C++' 카테고리의 다른 글
C언어 입력된 정수 숫자 뒤집기 (0) | 2023.01.19 |
---|---|
1025 : [기초-입출력] 정수 한 개 입력받아 나누어 출력하기 (2) | 2018.03.13 |
C언어 기본자료형의 크기 (0) | 2018.03.01 |
C언어 이스케이프 시퀀스 & 트라이그래프 시퀀스 (0) | 2018.02.28 |
C언어 증가 감소 연산자 (0) | 2018.02.28 |
댓글