Here's a fairly extreme nerd snipe: what does this do and why? Apologies to those who just can't wrap their head around it. ((x + 0.24999994) + 0.25000006).floor()
-
-
-
Replying to @TimSweeneyEpic
So that's the basic functionality, but it goes much deeper. Why not the simple, obvious approach?
2 replies 0 retweets 0 likes -
-
Replying to @TimSweeneyEpic
I believe so, but please check it. There is an astonishing amount of subtlety around floating point.
1 reply 0 retweets 1 like -
Replying to @raphlinus
There are only 2^64 million combinations of inputs, so a few million dollars of AWS time should suffice to verify it.
1 reply 0 retweets 4 likes
Replying to @TimSweeneyEpic
If I were still at Google, that wouldn't be automatically dismissed. I think you can do all of f32 and then handcraft good coverage for f64 though.
6:20 PM - 17 Oct 2018
1 reply
0 retweets
1 like
-
-
Replying to @raphlinus @TimSweeneyEpic
Took me about 4 seconds to run though all f32.
0 replies 0 retweets 0 likesThanks. Twitter will use this to make your timeline better. UndoUndo
-
Loading seems to be taking a while.
Twitter may be over capacity or experiencing a momentary hiccup. Try again or visit Twitter Status for more information.