By far, not all numbers’ exact decimal value can be represented in IEEE-754 standard.
For example
const n = Math.round(50.67587*1000)/1000; console.log(n);
50.676
I guess JavaScript is showing you a string here, cut to a certain number of digits, that looks like a number.
The actual closest representation of 50.676 is:
and so:
const f32 = new Float32Array(1); f32[0] = 50.676; console.log(f32[0])
50.67599868774414
