Median Sergey Svistunov

Find the median of 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 median value, printed as a decimal string. The median is defined as the element at index N/2 (i.e., a[50000000]) in the sorted array.

Back to listApr 19, 2024 18:07Joad NacerJoad NacerScore: 100,265Success
Source Code

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

Challenge History

No challenges yet.

Run Statistics
#DateScoreWall TimeCPU UserCPU SystemMemoryError
1Apr 19, 2024 18:0782,694746,214,870678,092,31902,297,856
2Apr 19, 2024 18:0783,981749,874,244688,644,01902,289,664
3Apr 19, 2024 18:0785,596770,023,402701,888,84902,289,664
4Apr 19, 2024 18:0786,552781,673,064709,725,36102,293,760
5Apr 19, 2024 18:0788,004781,477,142721,628,72702,289,664
6Apr 19, 2024 18:0792,021811,500,116754,572,83902,289,664
7Apr 19, 2024 18:07100,265886,492,994822,175,05102,289,664
8Apr 19, 2024 18:07101,600895,458,098833,116,07402,289,664
9Apr 19, 2024 18:07102,728911,280,619842,366,47402,297,856
10Apr 19, 2024 18:07104,915920,563,957860,303,06502,301,952
11Apr 19, 2024 18:07108,739959,544,037891,656,16202,297,856
12Apr 19, 2024 18:07116,7881,020,680,256957,660,16602,301,952