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:22Yuriy LyfenkoYuriy LyfenkoError
Source Code

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

Challenge History
DateChallengerCostTypeStatus
Jul 5, 2026 13:39Victor Mercklé10.00CustomSolution Broken
Run Statistics
#DateScoreWall TimeCPU UserCPU SystemMemoryError
1Jul 5, 2026 13:39036,614,33125,977,0001,132,0002,113,536expected "0 ", got "2147483648 "
2Jul 5, 2026 13:39036,331,92425,837,0001,125,0002,113,536expected "0 ", got "2147483648 "
3Jul 5, 2026 13:39036,313,53225,768,0001,107,0002,113,536expected "0 ", got "2147483648 "
4Apr 14, 2026 02:203,85856,566,77926,534,0005,102,0002,523,136
5Apr 14, 2026 02:203,86055,995,74427,569,0004,084,0002,359,296
6Apr 14, 2026 02:223,88560,580,51827,874,0003,982,0002,347,008
7Apr 14, 2026 02:223,89158,075,44127,921,0003,988,0002,359,296
8Apr 14, 2026 02:223,89258,158,69028,922,0002,991,0002,367,488
9Apr 14, 2026 02:203,89859,406,16928,968,0002,996,0002,506,752