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 23, 2026 02:16Josu San MartinJosu San MartinScore: 106,650Success
Source Code

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

Challenge History

No challenges yet.

Run Statistics
#DateScoreWall TimeCPU UserCPU SystemMemoryError
1Jan 23, 2026 02:16106,552547,556,533520,104,0002,000,0002,273,280
2Jan 23, 2026 02:16106,610548,832,531521,391,0001,000,0002,363,392
3Jan 23, 2026 02:16106,639556,126,230519,532,0002,997,0002,269,184
4Jan 23, 2026 02:16106,647558,432,514518,572,0003,996,0002,371,584
5Jan 23, 2026 02:16106,650551,210,518520,586,0001,998,0002,269,184
6Jan 23, 2026 02:16106,675549,974,539519,710,0002,998,0002,269,184
7Jan 23, 2026 02:16106,676552,959,499521,711,000999,0002,269,184
8Jan 23, 2026 02:16106,682552,496,310518,743,0003,998,0002,269,184
9Jan 23, 2026 02:16107,477559,110,018524,640,0001,998,0002,269,184