Answered step by step
Verified Expert Solution
Question
1 Approved Answer
why are int and long int same size? same for double and long double? When i google the difference it says that int is 32-bit
why are int and long int same size? same for double and long double? When i google the difference it says that int is 32-bit and long int is 64-bit. But this book says they are same?
\begin{tabular}{|l|l|l|l|} \hline \multicolumn{1}{|c|}{ Name } & \multicolumn{1}{|c|}{ Description } & \multicolumn{1}{c|}{ Size* } & \multicolumn{1}{c|}{ Range* } \\ \hline char & Character or small integer. & 1 byte & signed: 128 to 127 unsigned: 0 to 255 \\ \hline short int (short) & Short Integer. & signed: 32768 to 32767 unsigned: 0 to 65535 \\ \hline int & Integer. & signed: 2147483648 to 2147483647 unsigned: 0 to 4294967295 \\ \hline long int (long) & Long integer. & signed: 2147483648 to 2147483647 unsigned: 0 to 4294967295 \\ \hline bool & Boolean value. It can take one of two values: true or false. & 1 byte & true or false \\ \hline float & Floating point number. & 4 bytes & +/3.4e+/38(7 digits) \\ \hline double & Double precision floating point number. & 8 bytes & +/1.7e+/308(15 digits) \\ \hline long double & Long double precision floating point number. & 8 bytes & +/1.7e+/308(15 digits) \\ \hline wchar_t & Wide character. & 2 or 4 bytes & 1 wide character \\ \hline \end{tabular}Step by Step Solution
There are 3 Steps involved in it
Step: 1
Get Instant Access to Expert-Tailored Solutions
See step-by-step solutions with expert insights and AI powered tools for academic success
Step: 2
Step: 3
Ace Your Homework with AI
Get the answers you need in no time with our AI-driven, step-by-step assistance
Get Started