JavaScript

What is the output of `0.1 + 0.2 === 0.3`?

Medium
5
Added
false - due to floating-point precision errors

Solution Code

JavaScript
console.log(0.1 + 0.2); // 0.30000000000000004
Explanation
Binary floating-point cannot exactly represent decimal fractions

Guided Hints

Research IEEE 754 standard
How to properly compare floats?