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 20, 2026 02:06Victor MerckléVictor MerckléScore: 49,874Success
Source Code

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

Challenge History

No challenges yet.

Run Statistics
#DateScoreWall TimeCPU UserCPU SystemMemoryError
1Jun 20, 2026 02:0749,827252,176,375242,110,0002,044,0002,113,536
2Jun 20, 2026 02:0749,840252,021,272242,191,0002,029,0002,113,536
3Jun 20, 2026 02:0749,847251,882,059242,225,0002,028,0002,113,536
4Jun 20, 2026 02:0749,869252,056,238242,306,0002,055,0002,113,536
5Jun 20, 2026 02:0749,874252,350,788242,349,0002,034,0002,113,536
6Jun 20, 2026 02:0749,934252,261,279242,668,0002,009,0002,113,536
7Jun 20, 2026 02:0749,941252,303,673242,688,0002,023,0002,113,536
8Jun 20, 2026 02:0749,972252,470,227242,815,0002,050,0002,113,536
9Jun 20, 2026 02:0750,039252,869,387243,130,0002,063,0002,113,536