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 listNov 23, 2025 06:52RacRacScore: 407,772Success
Source Code

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

Challenge History

No challenges yet.

Run Statistics
#DateScoreWall TimeCPU UserCPU SystemMemoryError
1Nov 23, 2025 06:52407,6602,030,765,9661,996,537,000999,0002,387,968
2Nov 23, 2025 06:52407,6832,021,686,1981,994,650,0002,997,0002,269,184
3Nov 23, 2025 06:52407,6972,025,585,4291,995,716,0001,998,0002,387,968
4Nov 23, 2025 06:52407,7592,021,990,8471,995,022,0002,998,0002,269,184
5Nov 23, 2025 06:52407,7722,019,450,6181,998,082,00002,396,160
6Nov 23, 2025 06:52407,7932,022,051,2541,995,188,0002,998,0002,400,256
7Nov 23, 2025 06:52407,8392,025,852,7551,996,412,0001,998,0002,269,184
8Nov 23, 2025 06:52407,8742,022,644,9711,996,587,0001,998,0002,392,064
9Nov 23, 2025 06:52407,8772,026,293,4221,996,598,0001,998,0002,269,184