JavaScript uses IEEE 754 for storing numbers, for both integer and floating point values, where 53 bits are used for representing the mantissa and 11 bits are used for representing the exponent.
The maximum value representable with a signed 53 bit integer is ±9007199254740992, and the maximum value representable with a signed 11 bit integer is ±1024.
However, Number.MAX_VALUE
in JavaScript is 1.7976931348623157e+308
. Why isn’t it 9007199254740992e+1024
, which is possible to represent with 64 bits and is the larger value?
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With