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 listJun 20, 2021 14:18Andrey TsvetkovAndrey TsvetkovScore: 104,678Success
Source Code

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

Challenge History

No challenges yet.

Run Statistics
#DateScoreWall TimeCPU UserCPU SystemMemoryError
1Jun 20, 2021 14:1785,067761,907,695697,548,74802,265,088
2Jun 20, 2021 14:1886,022766,530,066705,378,98602,248,704
3Jun 20, 2021 14:1788,923784,309,720729,166,12102,269,184
4Jun 20, 2021 14:1895,101850,240,645779,830,21202,260,992
5Jun 20, 2021 14:18104,678922,276,759858,358,94002,265,088
6Jun 20, 2021 14:17106,254936,257,070871,280,96602,244,608
7Jun 20, 2021 14:18108,673959,361,871891,116,04002,252,800
8Jun 20, 2021 14:18113,233991,103,205928,513,38102,277,376
9Jun 20, 2021 14:18113,276984,654,509928,861,95502,207,744