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 listApr 9, 2023 16:53Franek KortaFranek KortaScore: 74,419Success
Source Code

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

Challenge History

No challenges yet.

Run Statistics
#DateScoreWall TimeCPU UserCPU SystemMemoryError
1Apr 9, 2023 16:5471,00845,899,18024,252,0002,021,0002,527,232
2Apr 9, 2023 16:5871,67047,663,64126,518,00002,531,328
3Apr 9, 2023 16:5472,71451,390,19924,912,0001,992,0002,437,120
4Apr 9, 2023 16:5372,79553,231,22425,937,000997,0002,527,232
5Apr 9, 2023 16:5372,97351,678,94023,885,0003,115,0002,437,120
6Apr 9, 2023 16:5473,01647,040,26924,015,0003,001,0002,527,232
7Apr 9, 2023 16:5873,02250,296,94825,017,0002,001,0002,441,216
8Apr 9, 2023 16:5473,14148,356,81526,060,0001,002,0002,437,120
9Apr 9, 2023 16:5473,16248,808,68125,065,0002,005,0002,433,024
10Apr 9, 2023 16:5873,31150,203,54126,121,0001,004,0002,531,328
11Apr 9, 2023 16:5873,45946,083,39526,174,0001,006,0002,437,120
12Apr 9, 2023 16:5873,47854,489,67226,181,0001,006,0002,269,184
13Apr 9, 2023 16:5373,59752,139,00026,223,0001,008,0002,527,232
14Apr 9, 2023 16:5873,84153,017,84427,321,00002,531,328
15Apr 9, 2023 16:5873,96846,574,16527,368,00002,269,184
16Apr 9, 2023 16:5874,06245,473,88726,389,0001,014,0002,445,312
17Apr 9, 2023 16:5374,07051,926,70826,391,0001,015,0002,437,120
18Apr 9, 2023 16:5374,39550,125,53627,526,00002,269,184
19Apr 9, 2023 16:5474,41952,240,91426,516,0001,019,0002,441,216
20Apr 9, 2023 16:5374,54353,023,48727,581,00002,437,120
21Apr 9, 2023 16:5374,78955,544,13227,672,00002,441,216
22Apr 9, 2023 16:5475,27053,096,98225,861,0001,989,0002,531,328
23Apr 9, 2023 16:5475,30360,677,03025,872,0001,990,0002,441,216
24Apr 9, 2023 16:5475,39252,095,92025,903,0001,992,0002,437,120
25Apr 9, 2023 16:5376,13548,608,88226,158,0002,012,0002,531,328
26Apr 9, 2023 16:5376,58456,336,77527,324,0001,012,0002,433,024
27Apr 9, 2023 16:5876,59249,730,57628,339,00002,269,184
28Apr 9, 2023 16:5479,242104,779,94529,319,69202,293,760
29Apr 9, 2023 16:5379,29590,003,25829,339,06302,170,880
30Apr 9, 2023 16:5379,42187,223,73829,385,64602,297,856
31Apr 9, 2023 16:5879,59487,773,41629,449,89002,293,760
32Apr 9, 2023 16:5380,44494,114,32829,764,45702,293,760
33Apr 9, 2023 16:5880,91591,658,67129,938,40202,170,880
34Apr 9, 2023 16:5480,99499,501,57229,967,84702,297,856
35Apr 9, 2023 16:5481,694102,464,42730,226,69802,293,760
36Apr 9, 2023 16:5881,97686,066,93030,331,25202,174,976