0
Size of various data types
What is the size of various data types including signed,unsigned, long and double?
6 Answers
+ 3
Some more information, to add to the previous posts,
http://www.tutorialspoint.com/cplusplus/cpp_data_types.htm
http://www.byte-notes.com/data-types-c
MSDN (Data ranges)
https://msdn.microsoft.com/en-us/library/s3f49ktz.aspx
Visual Studio C++
https://docs.microsoft.com/en-us/cpp/cpp/data-type-ranges
+ 1
It depends on the compiler and the architecture. Type sizeof(long); etc etc, which will give you the size of that type in bytes.
0
thanks aklex
0
yes, it depends on the size and architecture. But usually Signed char is 8 bit (-128 to 127), Unsigned char is 8 bit (0 to 255), double is 64 bit (0 to 64k-1) to long is 32 bit. but there are char like long signed, double Unsigned too.