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 listMay 13, 2026 05:47Victor MerckléVictor MerckléScore: 63,417Success
Source Code

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

Challenge History

No challenges yet.

Run Statistics
#DateScoreWall TimeCPU UserCPU SystemMemoryError
1May 13, 2026 05:5063,300318,891,275308,159,0002,011,0002,129,920
2May 13, 2026 05:5063,340318,933,400308,359,0002,009,0002,129,920
3May 13, 2026 05:5063,366319,191,228308,487,0002,007,0002,129,920
4May 13, 2026 05:5063,390319,519,036308,603,0002,009,0002,129,920
5May 13, 2026 05:5063,417319,401,126308,741,0002,006,0002,134,016
6May 13, 2026 05:5063,420319,463,386308,751,0002,008,0002,170,880
7May 13, 2026 05:5063,501319,871,425309,149,0002,008,0002,170,880
8May 13, 2026 05:5063,534320,082,790308,307,0003,010,0002,170,880
9May 13, 2026 05:5064,285323,759,269312,750,0002,247,0002,170,880