posted 10 years ago
What is the range for long. I know long can hold 64 bits. Using the formula -2^bits-1 to (2^bits-1)-1 and using the calculator I calculate the range to be:

-9223372036854775808 to 9223372036854775808

But on compile it says that this is out of range. Could someone please give me the correct range for long and let me know what is wrong here.

Many thanks,

Fes D Gaur