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 26, 2026 17:58Kevin HeaveyKevin HeaveyScore: 24,145Success
Source Code

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

Challenge History

No challenges yet.

Run Statistics
#DateScoreWall TimeCPU UserCPU SystemMemoryError
1Sep 26, 2026 17:5924,110128,646,249116,974,0001,169,00020,480
2Sep 26, 2026 17:5924,110129,249,371117,007,0001,133,00020,480
3Sep 26, 2026 17:5924,118129,153,536117,057,0001,124,00020,480
4Sep 26, 2026 17:5924,118129,444,774117,175,0001,004,00020,480
5Sep 26, 2026 17:5924,145129,314,244117,185,0001,126,00020,480
6Sep 26, 2026 17:5924,145128,242,098117,203,0001,108,00020,480
7Sep 26, 2026 17:5924,151129,748,589117,218,0001,126,00020,480
8Sep 26, 2026 17:5924,153129,575,943117,344,0001,009,00020,480
9Sep 26, 2026 17:5924,173129,391,062117,315,0001,137,00020,480