반응형
Notice
Recent Posts
Recent Comments
Link
일 | 월 | 화 | 수 | 목 | 금 | 토 |
---|---|---|---|---|---|---|
1 | ||||||
2 | 3 | 4 | 5 | 6 | 7 | 8 |
9 | 10 | 11 | 12 | 13 | 14 | 15 |
16 | 17 | 18 | 19 | 20 | 21 | 22 |
23 | 24 | 25 | 26 | 27 | 28 |
Tags
- STL
- Critical_Path_Analysis
- connected_component
- qsort
- 5397
- deletion
- data_structure
- 예제
- Algorithm
- 문법
- template
- Heap
- 구현
- 13305
- Pair
- class_template
- Articulation_Point
- singly Linked List
- '0'
- 자료구조
- 알고리즘
- sort
- list
- Biconnected_Component
- red-black tree
- 백준
- function_template
- c++
- sstream
- 총정리
Archives
- Today
- Total
- Today
- Total
- 방명록
어제의 나보다 성장한 오늘의 나
[c++] [자료형] int / double / char / float 크기 본문
반응형
c++ 에서 사용되는 메모리를 계산하다보면
변수 타입 마다 얼마의 메모리를 사용하는 지 궁금할 때가 있다.
그래서 오늘은 c++ 언어에서 각 자료형을 사용하는데 몇 byte가 드는지 알아보았다.
Coding
cout <<\
"sizeof_char : " << sizeof(char) << '\n' <<
"sizeof_int : " << sizeof(int) << '\n' <<
"sizeof_float : " << sizeof(float) << '\n' <<
"sizeof_double : " << sizeof(double);
반응형
'c++ > 문법' 카테고리의 다른 글
[C++] Unique 함수 정리 및 예제 (0) | 2022.02.13 |
---|---|
[c / c++] new / malloc / calloc /realloc 총 정리 & 예제 (0) | 2022.02.12 |
[C++] Sort 와 Compare 함수 (Greater , less) (0) | 2022.02.10 |
[C++] Pair 와 Tuple (0) | 2022.02.10 |
[c++] Template(템플릿) 총 정리 & 예제 (0) | 2022.02.10 |
Comments