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 7, 2026 10:39Victor MerckléVictor MerckléScore: 54,689Success
Source Code

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

Challenge History

No challenges yet.

Run Statistics
#DateScoreWall TimeCPU UserCPU SystemMemoryError
1Jun 7, 2026 10:4054,655277,052,192265,567,0002,243,0002,113,536
2Jun 7, 2026 10:4054,673277,058,905265,688,0002,213,0002,113,536
3Jun 7, 2026 10:4054,674277,043,773265,693,0002,212,0002,113,536
4Jun 7, 2026 10:4054,677277,012,813265,698,0002,220,0002,113,536
5Jun 7, 2026 10:4054,689277,166,404265,817,0002,161,0002,113,536
6Jun 7, 2026 10:4054,696277,648,087265,766,0002,245,0002,113,536
7Jun 7, 2026 10:4054,696277,193,458266,004,0002,008,0002,113,536
8Jun 7, 2026 10:4054,720277,734,113266,062,0002,066,0002,113,536
9Jun 7, 2026 10:4054,755277,427,493266,053,0002,251,0002,113,536