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 3, 2023 22:00Franek KortaFranek KortaScore: 72,589Success
Source Code

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

Challenge History

No challenges yet.

Run Statistics
#DateScoreWall TimeCPU UserCPU SystemMemoryError
1Apr 3, 2023 22:0072,03256,222,56726,652,00002,441,216
2Apr 3, 2023 22:0072,04356,747,59426,656,00002,437,120
3Apr 3, 2023 22:0072,08952,379,97826,673,00002,531,328
4Apr 3, 2023 22:0072,11454,076,25226,682,00002,531,328
5Apr 3, 2023 22:0072,54356,432,04924,853,0001,988,0002,531,328
6Apr 3, 2023 22:0072,55754,930,06524,858,0001,988,0002,527,232
7Apr 3, 2023 22:0072,58953,071,71023,874,0002,984,0002,437,120
8Apr 3, 2023 22:0072,59553,142,60225,866,000994,0002,449,408
9Apr 3, 2023 22:0072,62452,743,86225,876,000995,0002,441,216
10Apr 3, 2023 22:0076,32698,494,69028,240,79702,183,168
11Apr 3, 2023 22:0076,50479,866,41528,306,34002,297,856
12Apr 3, 2023 22:0076,72397,726,05528,387,55802,170,880