Hacker Newsnew | past | comments | ask | show | jobs | submitlogin

You mean ±9,007,199,254,740,993.0 for 64-bit floats. :-)

For other curious readers, these are one beyond the largest integer values that can be represented accurately. In other words, the next representable value away from zero after ±16,777,216.0 is ±16,777,218.0 in 32 bits -- the value ±16,777,217.0 cannot be represented, and will be rounded somewhat hand-wavingly (usually towards zero).

Precision rounding is one of those things that people often overlook.



Consider applying for YC's Fall 2026 batch! Applications are open till July 27.

Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: