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 listSep 24, 2026 15:58Andrew EpsteinAndrew EpsteinScore: 37,983Success
Source Code

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

Challenge History

No challenges yet.

Run Statistics
#DateScoreWall TimeCPU UserCPU SystemMemoryError
1Sep 24, 2026 15:5937,951196,434,622184,861,0001,099,0002,113,536
2Sep 24, 2026 15:5937,953196,373,007184,863,0001,107,0002,113,536
3Sep 24, 2026 15:5937,954196,389,589184,853,0001,125,0002,113,536
4Sep 24, 2026 15:5937,978197,276,376184,990,0001,104,0002,113,536
5Sep 24, 2026 15:5937,983196,660,451184,991,0001,127,0002,113,536
6Sep 24, 2026 15:5937,999196,610,435185,089,0001,109,0002,113,536
7Sep 24, 2026 15:5937,999196,745,864185,055,0001,143,0002,113,536
8Sep 24, 2026 15:5938,001197,609,980185,074,0001,132,0002,113,536
9Sep 24, 2026 15:5938,006196,701,292184,980,0001,251,0002,113,536