Format integers Sergey Svistunov

Compute a checksum over the decimal representations of binary integers as fast as possible.

Input: 250 000 000 uint32 values in little-endian binary on STDIN (4 bytes each).

Output: A uint64 checksum computed as:

CRC = sum of number_crc(n) for each n

where number_crc(n) converts n to its decimal string and sums ascii(digit) * position over each digit (0-indexed from the left).

Example: For n = 42, the decimal string is "42", so number_crc(42) = ascii('4') * 0 + ascii('2') * 1 = 52 * 0 + 50 * 1 = 50.

Back to listJun 25, 2026 12:58Victor MerckléVictor MerckléScore: 60,231Success
Source Code

Source code access is restricted. Log in to request access.

Challenge History

No challenges yet.

Run Statistics
#DateScoreWall TimeCPU UserCPU SystemMemoryError
1Jun 25, 2026 12:5960,121302,697,747292,429,0002,168,0002,113,536
2Jun 25, 2026 12:5960,124303,480,898292,566,0002,042,0002,113,536
3Jun 25, 2026 12:5960,176302,578,008292,784,0002,080,0002,113,536
4Jun 25, 2026 12:5960,202302,652,570292,939,0002,053,0002,113,536
5Jun 25, 2026 12:5960,231302,934,950293,017,0002,116,0002,113,536
6Jun 25, 2026 12:5960,255302,911,076293,184,0002,069,0002,113,536
7Jun 25, 2026 12:5960,266303,143,539293,204,0002,104,0002,113,536
8Jun 25, 2026 12:5962,585314,756,239304,566,0002,102,0002,113,536
9Jun 25, 2026 12:5962,614314,489,251304,745,0002,065,0002,113,536