Comment

Comment by anchpop

I think you're right. I produced a small rust program to test it by iterating over all 32-bit floats: https://gist.github.com/anchpop/30f119efd8d4c29a6a99202d57a5...

Output:

    Count between 0 and 1:    1065353215
    Count between 1 and +inf: 1073741824
    Ratio: 1.0
But a more theoretical approach will probably be needed to see if the same ratio exists for 64 bit floats.
parent anchpop 2 years ago

No comments yet

Be the first to share your thoughts.

Live from the official Hacker News API

A modern reader for Hacker News · SvelteKit + Skeleton