Hacker News new | ask | show | jobs
by dmd 2540 days ago
I'm pretty sure that 1.0 + 2.0 == 3.0 in IEEE 754. :) Now, 0.1 ...
4 comments

For reference to what they're talking about, the helpful https://0.30000000000000004.com/
One of the great qualities of IEEE 754 is its ability to represent many integers and operate on them without rounding errors.
Yep, sorry, meant to put 0.1 ...

Thanks!

They are not the same thing, but they are close enough most of the time.

The issue with floating point arrises when comparing very close numbers.