Introduction to C++
The variable's size is the amount of memory reserved by the compiler.
Depending on the variable type, the compiler reserves a certain number of bytes of your PC's memory.
sizeof() function allows you to determine the size of your variable or data type in bytes.
C++ allows you to select a type with an exact number of bits. For example, data types
To use them, you need to include the
"cstdint" header file.
We can also force the compiler to determine the variable type using
C++ also allows you to rename existing data types for yourself. This is what
typedef is used for:
When compiled, the
typedef line tells the compiler that
MY_NEW_TYPE is just a