All numbers in JavaScript are IEEE-754 double-precision numbers, which have a maximum number of ~15 significant digits. It's not Chrome, it's the nature of IEEE-754 double-precision floating point. When numbers get really big like that, they start becoming imprecise.
Undesirable long number rounding in Chrome
-
08-10-2022 - |
Question
How can it be possible, Chrome floor
ing the last 1
in a long number:
var a = 12345678987654321;
console.log("a =",a); // Traces: 12345678987654320
Fiddle: http://jsfiddle.net/zAXLx/
Solution
Licensed under: CC-BY-SA with attribution
Not affiliated with StackOverflow