Hacker News new | ask | show | jobs
by kangnkodos 2244 days ago
But on computers, you get things such as

console.log(0.1 + 0.2)

// 0.30000000000000004

A mathematician might say that this shows that you do not really have accurate floating point values and arithmetic in your computer, but instead something close to it.

1 comments

That's a coincidence of the particular number system you use, and many programming languages have multiple number implementations.

Racket starts with arbitrary precision rationals.