Why 10 + 6.99 Doesn't Equal 16.99: Understanding JavaScript's Floating-Point Math
If you've ever performed simple addition in JavaScript, only to find that the result isn't quite what you'd expect, you're not alone. Adding 10 + 6.99 might output 16.990000000000002 instead of the clean 16.99 you were expecting. What gives?
This