I noticed that if the fifteenth number after the dot is 1, then it will be lost.
For example, 13.949999999999991 will become 13.94999999999999 , but 13.949999999999998 will remain the same.
const a = 13.949999999999991;
const b = 13.949999999999998;
console.log(a); //13.94999999999999
console.log(b); //13.949999999999998
Why is this happening?
How can I fix this if number 13.949999999999991 comes from integration?
I’ve read stack overflow and other resources, but I haven’t found an answer.
New contributor
found_time is a new contributor to this site. Take care in asking for clarification, commenting, and answering.
Check out our Code of Conduct.