|
|
|
|
|
by nraynaud
4906 days ago
|
|
I don't know why "what every computer scientist should know about floating-point arithmetic" is not in here. Ruby or the last framework are just fads, but IEEE754 is here to stay and nobody know how to use it (and I never remember the details myself, I'm always struggling). |
|
They were first introduced in 1941 on the German made Z3 compuer. Whic means, yup, we can blame nazis for 0.1+0.2 == 0.30000000000000004
In all seriousness, more programmers need to understand this. I've seen more than a few beginners go rant about how awesome their language X is when contrast against language Y because language Y has bugs like 0.1+0.2 ... then they're blown away when the see their language too has the same "bug".