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 listOct 9, 2026 09:14Karthik ReddyKarthik ReddyScore: 23,827Success
Source Code

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

Challenge History

No challenges yet.

Run Statistics
#DateScoreWall TimeCPU UserCPU SystemMemoryError
1Oct 9, 2026 10:1123,770125,394,559115,381,0001,092,00020,480
2Oct 9, 2026 10:1123,791125,420,354115,491,0001,087,00020,480
3Oct 9, 2026 10:1123,794125,483,487115,495,0001,096,00020,480
4Oct 9, 2026 10:1123,826125,659,594115,664,0001,088,00020,480
5Oct 9, 2026 10:1123,827125,707,948115,594,0001,160,00020,480
6Oct 9, 2026 10:1123,830125,601,619115,682,0001,086,00020,480
7Oct 9, 2026 10:1123,839125,760,364115,682,0001,130,00020,480
8Oct 9, 2026 10:1123,868125,853,208115,845,0001,110,00020,480
9Oct 9, 2026 10:1123,891127,464,930115,976,0001,090,00020,480