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 listJun 28, 2026 09:18Shikhar SoniShikhar SoniScore: 120,294Success
Source Code

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

Challenge History

No challenges yet.

Run Statistics
#DateScoreWall TimeCPU UserCPU SystemMemoryError
1Jun 28, 2026 09:19119,100592,941,893581,538,0002,054,0002,113,536
2Jun 28, 2026 09:19119,546595,083,440583,739,0002,038,0002,113,536
3Jun 28, 2026 09:19119,844596,579,620585,222,0002,017,0002,113,536
4Jun 28, 2026 09:19120,026597,445,923586,129,0002,002,0002,113,536
5Jun 28, 2026 09:19120,294605,926,127587,441,0002,004,0002,113,536
6Jun 28, 2026 09:19120,365599,271,659587,771,0002,022,0002,113,536
7Jun 28, 2026 09:19120,428599,486,731587,885,0002,216,0002,113,536
8Jun 28, 2026 09:19122,638610,318,017598,879,0002,051,0002,113,536
9Jun 28, 2026 09:19126,639640,931,278617,483,0003,051,0002,113,536