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 11, 2025 13:52Yehor BondarYehor BondarScore: 2,844,839Success
Source Code

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

Challenge History

No challenges yet.

Run Statistics
#DateScoreWall TimeCPU UserCPU SystemMemoryError
1Nov 11, 2025 13:522,843,02113,961,814,68513,792,884,000137,918,0002,277,376
2Nov 11, 2025 13:522,843,02213,962,804,83513,793,878,000136,929,0002,277,376
3Nov 11, 2025 13:522,843,70213,969,927,95913,812,207,000121,931,0002,277,376
4Nov 11, 2025 13:522,844,59113,971,548,23713,810,563,000127,931,0002,277,376
5Nov 11, 2025 13:522,844,83913,971,222,83913,807,781,000131,931,0002,277,376
6Nov 11, 2025 13:522,846,79413,981,869,52613,824,368,000124,922,0002,277,376
7Nov 11, 2025 13:522,846,79713,982,405,58113,820,367,000128,938,0002,277,376
8Nov 11, 2025 13:522,847,64113,990,103,78813,824,513,000128,930,0002,519,040
9Nov 11, 2025 13:522,961,85014,549,209,21314,385,128,000127,938,0002,277,376