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 listNov 5, 2025 16:59AntonAntonScore: 442,911Success
Source Code

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

Challenge History

No challenges yet.

Run Statistics
#DateScoreWall TimeCPU UserCPU SystemMemoryError
1Nov 5, 2025 16:59442,7632,195,768,6662,167,541,0001,998,0002,301,952
2Nov 5, 2025 16:59442,7852,201,313,2752,167,650,0001,998,0002,285,568
3Nov 5, 2025 16:59442,7962,198,271,4762,167,700,0001,998,0002,551,808
4Nov 5, 2025 16:59442,8052,195,525,1572,166,746,0002,998,0002,543,616
5Nov 5, 2025 16:59442,9112,201,924,3852,168,264,0001,999,0002,297,856
6Nov 5, 2025 16:59442,9372,203,612,9712,168,394,0001,998,0002,547,712
7Nov 5, 2025 16:59442,9712,195,130,0332,169,560,000999,0002,297,856
8Nov 5, 2025 16:59442,9742,197,005,3472,169,573,000999,0002,297,856
9Nov 5, 2025 16:59443,0212,197,316,2352,167,805,0002,998,0002,535,424