Skip to content

Latest commit

 

History

History
11 lines (8 loc) · 450 Bytes

get-machine-epsilon-value.md

File metadata and controls

11 lines (8 loc) · 450 Bytes

Get machine epsilon value in JavaScript

To find the machine epsilon value for JavaScript, use Number.EPSILON. This is effectively the maximum possible rounding error for floating point numbers.

// Number.EPSILON
Math.abs(0.2 - 0.3 + 0.1) < Number.EPSILON
// true

See the docs.