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 14, 2026 02:38Yuriy LyfenkoYuriy LyfenkoError
Source Code

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

Challenge History
DateChallengerCostTypeStatus
Jul 5, 2026 13:17Victor Mercklé10.00CustomSolution Broken
Run Statistics
#DateScoreWall TimeCPU UserCPU SystemMemoryError
1Jul 5, 2026 13:17035,814,82025,284,0001,081,0002,117,632expected "0 ", got "2147483648 "stderr
2Jul 5, 2026 13:17035,827,51425,219,0001,064,0002,117,632expected "0 ", got "2147483648 "stderr
3Jul 5, 2026 13:17035,691,55325,264,0001,077,0002,117,632expected "0 ", got "2147483648 "stderr
4Apr 14, 2026 02:383,57756,616,64327,311,0002,023,0002,437,120
5Apr 14, 2026 02:383,59456,456,86925,409,0004,065,0002,269,184
6Apr 14, 2026 02:383,59750,530,96426,445,0003,051,0002,502,656
7Apr 14, 2026 02:383,60257,763,04528,516,0001,018,0002,506,752
8Apr 14, 2026 02:383,60556,233,28727,525,0002,038,0002,297,856
9Apr 14, 2026 02:383,61148,058,76726,545,0003,062,0002,482,176