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 listJul 31, 2026 20:21Josu San MartinJosu San MartinScore: 47,857Success
Source Code

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

Challenge History

No challenges yet.

Run Statistics
#DateScoreWall TimeCPU UserCPU SystemMemoryError
1Jul 31, 2026 20:2247,575244,103,434232,003,0001,115,0002,113,536
2Jul 31, 2026 20:2247,595244,106,263232,094,0001,122,0002,113,536
3Jul 31, 2026 20:2247,601244,594,641232,115,0001,131,0002,113,536
4Jul 31, 2026 20:2247,836244,627,722233,258,0001,141,0002,113,536
5Jul 31, 2026 20:2247,857244,625,032233,383,0001,120,0002,113,536
6Jul 31, 2026 20:2247,879244,710,533233,501,0001,109,0002,113,536
7Jul 31, 2026 20:2247,927245,697,068233,705,0001,138,0002,113,536
8Jul 31, 2026 20:2247,943245,847,341233,818,0001,103,0002,113,536
9Jul 31, 2026 20:2248,014245,358,574234,135,0001,134,0002,113,536