Converting floating-point numbers to integers while preserving order | Hacker News Reader