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 listJul 2, 2026 18:06Victor MerckléVictor MerckléScore: 50,536Success
Source Code

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

Challenge History

No challenges yet.

Run Statistics
#DateScoreWall TimeCPU UserCPU SystemMemoryError
1Jul 2, 2026 18:0750,407254,712,289244,979,0002,017,0002,117,632stderr
2Jul 2, 2026 18:0750,492255,187,383245,356,0002,055,0002,117,632stderr
3Jul 2, 2026 18:0750,526255,395,057245,414,0002,164,0002,117,632stderr
4Jul 2, 2026 18:0750,528255,271,610245,509,0002,081,0002,117,632stderr
5Jul 2, 2026 18:0750,536256,947,891245,549,0002,080,0002,117,632stderr
6Jul 2, 2026 18:0750,553255,402,815245,610,0002,100,0002,117,632stderr
7Jul 2, 2026 18:0750,592255,584,164245,860,0002,044,0002,117,632stderr
8Jul 2, 2026 18:0750,608255,704,202245,906,0002,078,0002,117,632stderr
9Jul 2, 2026 18:0751,182258,497,305248,676,0002,118,0002,117,632stderr