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 listOct 7, 2026 04:39Karthik ReddyKarthik ReddyScore: 23,820Success
Source Code

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

Challenge History

No challenges yet.

Run Statistics
#DateScoreWall TimeCPU UserCPU SystemMemoryError
1Oct 7, 2026 04:4023,780125,560,265115,413,0001,110,0002,113,536
2Oct 7, 2026 04:4023,785125,606,550115,436,0001,112,0002,113,536
3Oct 7, 2026 04:4023,808125,596,970115,642,0001,022,0002,113,536
4Oct 7, 2026 04:4023,817125,769,780115,674,0001,030,0002,113,536
5Oct 7, 2026 04:4023,820125,727,869115,691,0001,030,0002,113,536
6Oct 7, 2026 04:4023,848125,849,742115,825,0001,035,0002,113,536
7Oct 7, 2026 04:4023,851125,868,644115,758,0001,114,0002,113,536
8Oct 7, 2026 04:4023,863125,884,981115,829,0001,100,0002,113,536
9Oct 7, 2026 04:4023,881126,029,888115,909,0001,108,0002,113,536