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 5, 2026 21:49Victor MerckléVictor MerckléScore: 58,203Success
Source Code

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

Challenge History

No challenges yet.

Run Statistics
#DateScoreWall TimeCPU UserCPU SystemMemoryError
1Jun 5, 2026 21:4958,090293,815,997282,611,0002,033,0002,113,536
2Jun 5, 2026 21:4958,130293,940,581282,795,0002,043,0002,113,536
3Jun 5, 2026 21:4958,134293,938,008282,789,0002,068,0002,113,536
4Jun 5, 2026 21:4958,184294,198,485283,084,0002,018,0002,113,536
5Jun 5, 2026 21:4958,203294,359,142283,157,0002,039,0002,113,536
6Jun 5, 2026 21:4958,203294,390,207283,127,0002,070,0002,113,536
7Jun 5, 2026 21:4958,245294,583,062283,384,0002,021,0002,113,536
8Jun 5, 2026 21:4958,739296,952,808285,797,0002,026,0002,113,536
9Jun 5, 2026 21:4958,794297,218,180286,060,0002,031,0002,113,536