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 28, 2026 01:00Kevin HeaveyKevin HeaveyScore: 54,497Success
Source Code

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

Challenge History

No challenges yet.

Run Statistics
#DateScoreWall TimeCPU UserCPU SystemMemoryError
1Jul 28, 2026 08:0753,946274,354,645254,831,0009,507,00020,480
2Jul 28, 2026 08:0754,047274,878,425255,388,0009,444,00020,480
3Jul 28, 2026 08:0754,170276,140,225255,606,0009,831,0002,113,536
4Jul 28, 2026 08:0754,361277,128,426255,831,00010,541,00020,480
5Jul 28, 2026 08:0754,497277,802,666255,951,00011,088,00020,480
6Jul 28, 2026 08:0754,521277,907,711255,492,00011,662,00020,480
7Jul 28, 2026 08:0754,541277,227,165256,008,00011,243,00020,480
8Jul 28, 2026 08:0755,395281,604,906259,530,00011,907,00020,480
9Jul 28, 2026 08:0756,288286,460,173264,716,00011,096,00020,480