How is constant stored in the memory? (+ Python Integer caching)
2022. 1. 29. 20:48
👉🏻일반적인 변수가 메모리의 어디에 저장되는지) https://goldenriver42.tistory.com/67?category=936334
C언어의 경우 5, 10 같은 숫자들은 메모리에 저장되지 않음.
CPython의 Integer caching과 비슷하다고 생각해도 될까?
https://stackoverflow.com/questions/21735890/where-and-how-are-constants-stored
Where and how are constants stored?
I read this question from here and I also read related question from c-faq but I don't understand the exact reason behind this :- #include <iostream> using namespace std; int main...
stackoverflow.com
'<언어> > [C]' 카테고리의 다른 글
배열(Array) 생성 (0) | 2021.10.07 |
---|---|
변수, 포인터는 선언(declaration)만 해도 메모리를 차지하는가? + void 포인터 활용 (0) | 2021.09.28 |
memset 초기화 (0) | 2021.08.12 |
Passing C-style 1-D/2-D array as a parameter (0) | 2021.03.17 |
후위 증감연산자와 *ptr++ (0) | 2021.03.17 |