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 listOct 14, 2024 17:52Joad NacerJoad NacerScore: 62,400Success
Source Code

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

Challenge History

No challenges yet.

Run Statistics
#DateScoreWall TimeCPU UserCPU SystemMemoryError
1Oct 14, 2024 17:5262,09547,440,64420,978,0001,997,0002,433,024
2Oct 14, 2024 17:5262,25950,019,86521,033,0002,003,0002,424,832
3Oct 14, 2024 17:5262,32245,226,15222,057,0001,002,0002,273,280
4Oct 14, 2024 17:5262,35945,771,02122,070,0001,003,0002,437,120
5Oct 14, 2024 17:5262,40044,823,95223,088,00002,535,424
6Oct 14, 2024 17:5262,51644,098,39721,120,0002,011,0002,433,024
7Oct 14, 2024 17:5262,54148,309,73821,128,0002,012,0002,437,120
8Oct 14, 2024 17:5262,72450,928,56921,190,0002,018,0002,273,280
9Oct 14, 2024 17:5265,75150,881,43723,315,0001,013,0002,433,024