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 listMar 7, 2023 20:16Franek KortaFranek KortaScore: 980,771Success
Source Code

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

Challenge History

No challenges yet.

Run Statistics
#DateScoreWall TimeCPU UserCPU SystemMemoryError
1Mar 7, 2023 20:16974,4178,047,633,4547,990,215,50702,195,456
2Mar 7, 2023 20:16974,6578,053,744,7627,992,183,51802,191,360
3Mar 7, 2023 20:15976,5728,063,099,2928,007,888,31102,191,360
4Mar 7, 2023 20:16977,8928,081,884,5358,018,715,89502,183,168
5Mar 7, 2023 20:15978,0568,077,265,1048,020,058,09502,183,168
6Mar 7, 2023 20:15978,3648,079,542,0628,022,584,05102,179,072
7Mar 7, 2023 20:16980,7718,102,093,2238,042,319,99302,187,264
8Mar 7, 2023 20:16981,4198,099,732,7948,047,638,05002,179,072
9Mar 7, 2023 20:16982,1228,107,924,3128,053,396,94402,187,264
10Mar 7, 2023 20:16982,2048,112,341,9358,054,069,60302,187,264
11Mar 7, 2023 20:16983,0698,214,432,8308,061,165,99202,236,416
12Mar 7, 2023 20:16985,3538,135,694,6658,079,895,55602,187,264