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 4, 2026 03:35zielajzielajError
Source Code

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

Challenge History
DateChallengerCostTypeStatus
Jul 4, 2026 09:15Victor Mercklé10.00CustomSolution Broken
Run Statistics
#DateScoreWall TimeCPU UserCPU SystemMemoryError
1Jul 4, 2026 09:16043,457,60618,176,00017,255,00020,480No answer to stdout. Died or killed?stderr
2Jul 4, 2026 03:3624,167126,454,116116,368,0002,051,0002,121,728stderr
3Jul 4, 2026 03:3624,191126,909,245116,495,0002,045,0002,121,728stderr
4Jul 4, 2026 03:3624,208126,596,433116,534,0002,087,0002,121,728stderr
5Jul 4, 2026 03:3624,245127,090,325116,755,0002,048,0002,121,728stderr
6Jul 4, 2026 03:3624,255127,044,698116,808,0002,044,0002,121,728stderr
7Jul 4, 2026 03:3624,270126,875,185116,885,0002,042,0002,121,728stderr
8Jul 4, 2026 03:3624,282126,906,441116,937,0002,047,0002,121,728stderr
9Jul 4, 2026 03:3624,294126,974,918116,993,0002,048,0002,121,728stderr
10Jul 4, 2026 03:3625,978135,388,439125,208,0002,085,0002,121,728stderr