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 28, 2024 17:00Matthew SillsMatthew SillsScore: 118,481Success
Source Code

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

Challenge History

No challenges yet.

Run Statistics
#DateScoreWall TimeCPU UserCPU SystemMemoryError
1Jul 28, 2024 17:00117,52265,886,13543,483,00002,535,424
2Jul 28, 2024 17:00117,67066,303,49643,538,00002,433,024
3Jul 28, 2024 17:00117,73070,198,12443,560,00002,433,024
4Jul 28, 2024 17:00117,88171,486,72142,602,0001,014,0002,535,424
5Jul 28, 2024 17:00117,93572,156,72543,636,00002,437,120
6Jul 28, 2024 17:00118,47870,515,61243,837,00002,273,280
7Jul 28, 2024 17:00118,48172,019,26143,838,00002,535,424
8Jul 28, 2024 17:00118,63865,781,94741,901,0001,995,0002,535,424
9Jul 28, 2024 17:00118,71665,689,65242,927,000998,0002,535,424
10Jul 28, 2024 17:00133,414100,431,35649,363,33802,289,664
11Jul 28, 2024 17:00133,455103,709,64849,378,43202,277,376
12Jul 28, 2024 17:00133,711103,915,36849,473,12002,289,664