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 listOct 19, 2024 18:32zielajzielajError
Source Code

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

Challenge History
DateChallengerCostTypeStatus
Jul 5, 2026 12:27Victor Mercklé10.00CustomSolution Broken
Run Statistics
#DateScoreWall TimeCPU UserCPU SystemMemoryError
1Jul 5, 2026 12:2709,248,2961,094,000020,480No answer to stdout. Died or killed?
2Oct 19, 2024 18:323,16149,279,55123,927,0001,993,0002,433,024
3Oct 19, 2024 18:323,16150,848,02823,929,0001,994,0002,285,568
4Oct 19, 2024 18:323,16246,601,14724,928,000997,0002,506,752
5Oct 19, 2024 18:323,17348,345,21824,021,0002,001,0002,420,736
6Oct 19, 2024 18:323,17853,576,67624,058,0002,004,0002,408,448
7Oct 19, 2024 18:323,18152,504,11725,078,0001,003,0002,465,792
8Oct 19, 2024 18:323,20052,500,07924,218,0002,018,0002,453,504
9Oct 19, 2024 18:323,20854,660,77823,272,0003,035,0002,400,256
10Oct 19, 2024 18:323,21047,628,82024,299,0002,024,0002,416,640