Hacker News new | ask | show | jobs
by closedl00p 485 days ago
Thanks for sharing! I found an amusing math bug in the basic calculator:

0 + 0.00000001 gives 1e-8 (I see you’re displaying in scientific notation, hmm— I wonder how you’re storing it internally…)

Then multiplying that by 5 gives… -39.

Somehow 1e-8 * 5 is being parsed as 1 + (-8 * 5)?