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 listSep 24, 2026 13:48Andrew EpsteinAndrew EpsteinScore: 422,106Success
Source Code

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

Challenge History

No challenges yet.

Run Statistics
#DateScoreWall TimeCPU UserCPU SystemMemoryError
1Sep 24, 2026 13:49422,0402,078,425,1492,066,970,0001,027,0002,117,632stderr
2Sep 24, 2026 13:49422,0792,078,535,9942,067,181,0001,010,0002,117,632stderr
3Sep 24, 2026 13:49422,0832,078,604,0872,067,195,0001,013,0002,117,632stderr
4Sep 24, 2026 13:49422,0972,078,679,8552,067,280,0001,000,0002,117,632stderr
5Sep 24, 2026 13:49422,1062,079,453,2942,067,318,0001,003,0002,117,632stderr
6Sep 24, 2026 13:49422,1592,079,176,9682,067,580,0001,003,0002,117,632stderr
7Sep 24, 2026 13:49422,1662,078,900,6972,067,604,0001,010,0002,117,632stderr
8Sep 24, 2026 13:49422,3422,079,942,3502,068,475,0001,005,0002,117,632stderr
9Sep 24, 2026 13:49422,5502,080,825,7412,069,494,0001,003,0002,117,632stderr