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 listJan 21, 2026 23:08Josu San MartinJosu San MartinScore: 114,877Success
Source Code

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

Challenge History

No challenges yet.

Run Statistics
#DateScoreWall TimeCPU UserCPU SystemMemoryError
1Jan 21, 2026 23:08114,807595,768,200558,559,0003,996,0002,449,408
2Jan 21, 2026 23:08114,813593,673,499557,590,0004,996,0002,453,504
3Jan 21, 2026 23:08114,831592,608,652557,674,0004,997,0002,281,472
4Jan 21, 2026 23:08114,851588,632,596557,771,0004,997,0002,457,600
5Jan 21, 2026 23:08114,877594,187,402558,896,0003,999,0002,281,472
6Jan 21, 2026 23:08114,895586,763,499556,987,0005,999,0002,445,312
7Jan 21, 2026 23:08114,897589,635,386560,998,0001,999,0002,281,472
8Jan 21, 2026 23:08114,901587,202,687560,017,0003,000,0002,281,472
9Jan 21, 2026 23:08114,996590,629,913558,487,0004,995,0002,457,600