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 6, 2025 15:09AntonAntonScore: 182,078Success
Source Code

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

Challenge History

No challenges yet.

Run Statistics
#DateScoreWall TimeCPU UserCPU SystemMemoryError
1Nov 6, 2025 15:09175,680888,974,499857,834,0002,999,0002,297,856
2Nov 6, 2025 15:09177,911898,769,499869,761,0002,001,0002,306,048
3Nov 6, 2025 15:09178,897908,036,117874,597,0001,999,0002,441,216
4Nov 6, 2025 15:09180,138911,745,833880,678,0001,999,0002,445,312
5Nov 6, 2025 15:09182,078925,295,641890,181,0002,000,0002,441,216
6Nov 6, 2025 15:09183,069924,205,146894,039,0003,000,0002,297,856
7Nov 6, 2025 15:09185,829935,798,291908,562,0001,999,0002,293,760
8Nov 6, 2025 15:09186,466939,614,154910,685,0002,998,0002,301,952
9Nov 6, 2025 15:09188,569955,862,292921,988,0001,999,0002,469,888