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 12, 2025 01:15zielajzielajScore: 48,846Success
Source Code

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

Challenge History

No challenges yet.

Run Statistics
#DateScoreWall TimeCPU UserCPU SystemMemoryError
1Jul 12, 2025 01:1548,286261,351,077235,604,000998,0002,478,080
2Jul 12, 2025 01:1548,304260,904,618235,692,000998,0002,457,600
3Jul 12, 2025 01:1548,319265,632,644234,765,0001,998,0002,424,832
4Jul 12, 2025 01:1548,380261,701,946235,063,0002,000,0002,453,504
5Jul 12, 2025 01:1548,846263,207,699239,343,00002,457,600
6Jul 12, 2025 01:1548,854264,412,764238,382,0001,001,0002,424,832
7Jul 12, 2025 01:1548,894268,468,704236,586,0002,994,0002,420,736
8Jul 12, 2025 01:1551,045275,107,190250,121,00002,433,024
9Jul 12, 2025 01:1551,252275,172,116251,137,00002,461,696