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 9, 2026 08:46Victor MerckléVictor MerckléScore: 37,818Success
Source Code

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

Challenge History

No challenges yet.

Run Statistics
#DateScoreWall TimeCPU UserCPU SystemMemoryError
1Jul 9, 2026 08:4737,276190,716,300171,340,00011,315,00024,576stderr
2Jul 9, 2026 08:4737,405191,140,747170,725,00012,562,00024,576stderr
3Jul 9, 2026 08:4737,737192,758,511171,309,00013,607,00024,576stderr
4Jul 9, 2026 08:4737,767192,929,377172,022,00013,037,0002,117,632stderr
5Jul 9, 2026 08:4737,818193,435,303171,999,00013,311,00024,576stderr
6Jul 9, 2026 08:4737,954194,006,662172,866,00013,110,00024,576stderr
7Jul 9, 2026 08:4738,348195,810,546172,317,00015,592,0002,117,632stderr
8Jul 9, 2026 08:4738,408196,166,871173,726,00014,478,00024,576stderr
9Jul 9, 2026 08:4738,518196,709,084172,921,00015,822,00024,576stderr