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 listMay 19, 2021 22:54Yuriy LyfenkoYuriy LyfenkoScore: 364,563Success
Source Code

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

Challenge History

No challenges yet.

Run Statistics
#DateScoreWall TimeCPU UserCPU SystemMemoryError
1May 19, 2021 22:54294,5771,508,077,7741,443,427,83002,179,072
2May 19, 2021 22:45294,9681,501,728,4961,445,342,15302,195,456
3May 19, 2021 21:37296,2101,511,814,0461,451,429,82802,187,264
4May 19, 2021 21:37296,2141,513,582,4711,451,450,18002,195,456
5May 19, 2021 22:45296,3721,519,853,5091,452,221,36302,183,168
6May 20, 2021 03:23296,3801,521,787,2901,452,264,03402,183,168
7May 19, 2021 22:45296,5401,523,267,7391,453,048,37402,195,456
8May 20, 2021 03:23296,6111,511,168,4851,453,392,41602,191,360
9May 19, 2021 22:54296,7721,506,762,2341,454,182,23402,191,360
10May 20, 2021 03:23298,2661,524,324,7381,461,501,50202,195,456
11May 19, 2021 22:54300,9041,535,675,1921,474,430,86402,195,456
12May 19, 2021 21:37305,3991,561,901,9261,496,455,08102,191,360
13May 19, 2021 22:54364,1511,850,233,1261,784,342,03602,183,168
14May 20, 2021 03:23364,1971,860,730,7541,784,563,83002,195,456
15May 19, 2021 21:37364,2571,850,108,9661,784,857,52802,195,456
16May 19, 2021 22:54364,3741,853,924,8181,785,432,96402,191,360
17May 19, 2021 22:45364,3841,854,085,5971,785,479,89102,183,168
18May 20, 2021 03:23364,5021,841,722,8871,786,059,75902,183,168
19May 20, 2021 03:23364,5631,850,111,6711,786,360,52402,187,264
20May 19, 2021 21:37364,8091,847,473,7721,787,561,83202,187,264
21May 19, 2021 22:54364,8701,844,523,5021,787,862,77602,191,360
22May 19, 2021 22:45364,8921,853,733,5811,787,971,56602,191,360
23May 19, 2021 22:45364,9561,849,710,0091,788,282,17602,183,168
24May 19, 2021 21:37365,0021,850,587,1351,788,508,34802,195,456
25May 19, 2021 22:45365,0511,853,907,7421,788,749,11702,179,072
26May 20, 2021 03:23365,0851,838,932,5281,788,916,51802,187,264
27May 19, 2021 21:37365,2891,843,430,3931,789,914,38202,195,456
28May 20, 2021 03:23365,4071,858,428,0331,790,493,78702,187,264
29May 19, 2021 21:37365,5861,854,304,2671,791,373,33002,199,552
30May 19, 2021 22:54365,6271,850,694,8041,791,573,51702,191,360
31May 19, 2021 22:54365,6491,865,885,7601,791,680,13302,183,168
32May 19, 2021 22:45365,9051,846,735,7611,792,934,23802,203,648
33May 19, 2021 21:37365,9261,850,939,7371,793,036,83802,187,264
34May 19, 2021 22:54366,0021,848,028,6461,793,409,35102,195,456
35May 19, 2021 22:45366,2971,853,023,3791,794,854,47102,179,072
36May 20, 2021 03:23366,7801,864,779,6091,797,219,92802,183,168