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 listMay 20, 2024 20:19Joad NacerJoad NacerError
Source Code

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

Challenge History

No challenges yet.

Run Statistics
#DateScoreWall TimeCPU UserCPU SystemMemoryError
1May 20, 2024 20:2000000Error: No answer to stdout. Died or killed?
2May 20, 2024 20:2000000Error: expected "2193230393 ", got "0"stderr
3May 20, 2024 23:0300000Error: No answer to stdout. Died or killed?stderr
4May 29, 2024 21:019,860149,997,54680,852,46902,260,992
5May 29, 2024 21:0110,003151,365,78582,024,41002,203,648
6May 20, 2024 20:1910,103164,652,67282,848,00802,248,704
7May 20, 2024 20:1910,157158,562,35183,287,14102,183,168
8May 29, 2024 21:0110,689154,344,64687,653,78802,297,856
9May 20, 2024 20:1911,447148,067,13793,861,40502,265,088