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 21:58Franek KortaFranek KortaScore: 72,570Success
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 21:5872,00553,029,78225,618,0001,024,0002,527,232
2Apr 3, 2023 21:5872,07859,075,71326,669,00002,265,088
3Apr 3, 2023 21:5872,14359,213,78625,667,0001,026,0002,441,216
4Apr 3, 2023 21:5872,14653,220,30525,668,0001,026,0002,437,120
5Apr 3, 2023 21:5872,15157,591,04626,696,00002,449,408
6Apr 3, 2023 21:5872,44954,322,44924,821,0001,985,0002,269,184
7Apr 3, 2023 21:5872,57057,571,07024,862,0001,989,0002,269,184
8Apr 3, 2023 21:5872,59250,526,59125,865,000994,0002,449,408
9Apr 3, 2023 21:5872,59553,207,49525,866,000994,0002,531,328
10Apr 3, 2023 21:5876,04684,598,87228,137,10202,301,952
11Apr 3, 2023 21:5876,05792,034,11328,141,07302,301,952
12Apr 3, 2023 21:5876,52795,257,23928,315,16602,301,952