TopK Sergey Svistunov

Find the sum of the 100 largest values in a stream of binary integers as fast as possible.

Input: 100 000 000 uint32 values in little-endian binary on STDIN (4 bytes each).

Output: The uint64 sum of the top 100 greatest values, printed as a decimal string.

Back to listJul 13, 2021 10:23Andrey TsvetkovAndrey TsvetkovScore: 121,216Success
Source Code

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

Challenge History

No challenges yet.

Run Statistics
#DateScoreWall TimeCPU UserCPU SystemMemoryError
1Jul 13, 2021 10:23119,91969,240,35342,354,0002,016,0002,326,528
2Jul 13, 2021 10:23120,21969,223,20542,460,0002,021,0002,523,136
3Jul 13, 2021 10:23120,48974,648,61443,568,0001,013,0002,334,720
4Jul 13, 2021 10:23120,57671,029,06543,600,0001,013,0002,531,328
5Jul 13, 2021 10:23120,77374,630,06543,671,0001,015,0002,334,720
6Jul 13, 2021 10:23120,86871,733,76442,689,0002,032,0002,531,328
7Jul 13, 2021 10:23121,21676,854,66842,857,0001,993,0002,334,720
8Jul 13, 2021 10:23121,43574,077,48141,936,0002,995,0002,334,720
9Jul 13, 2021 10:23121,69573,153,77643,026,0002,001,0002,334,720
10Jul 13, 2021 10:23122,140115,187,87445,191,88002,207,744
11Jul 13, 2021 10:23122,551111,703,65745,343,87802,215,936
12Jul 13, 2021 10:23122,846101,405,46945,453,15702,211,840