After spending hours trying to figure out an error in my personal accounting spreadsheet, I could pin it up to one formula.

While this results in Zero

``````=((0,6-0,3-0,4)+(-0,3+0,8-0,4))
``````

comparing it with Zero gives me false

``````=((0,6-0,3-0,4)+(-0,3+0,8-0,4))=0
``````

What the heck am I missing?

• Have you never encountered the joys of floating point math?
– ale
Commented Jul 10, 2015 at 23:15
• Yes I did (in the worse way) with Javascript. But don't Google Spreeadsheets math computation occurs server side? Commented Jul 10, 2015 at 23:19
• Probably. I'm afraid I don't have an answer for you. I just found it a little funny that here's another domain where `0 != 0`.
– ale
Commented Jul 10, 2015 at 23:21
• Perhaps you could check if it's less than or equal to the smallest number. Commented Jul 11, 2015 at 23:50
• "After spending hours trying to figure out an error in my personal accounting spreadsheet" - love that :D glad I'm not the only person who waste time this way ;)
– Line
Commented Oct 19, 2018 at 7:51

``````((0.6-0.3-0.4)+(-0.3+0.8-0.4))
• My solution was to `=FLOOR(B3+C2, 0.01)` for working with currency Commented Jul 28, 2018 at 3:03