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 listJul 15, 2023 06:42Paul MasurelPaul MasurelScore: 20,885Success
Source Code

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

Challenge History

No challenges yet.

Run Statistics
#DateScoreWall TimeCPU UserCPU SystemMemoryError
1Jul 15, 2023 06:425,74376,890,38941,084,0006,012,0002,383,872
2Jul 15, 2023 06:426,07977,229,81143,868,0005,982,0002,461,696
3Jul 15, 2023 06:426,205129,460,82150,882,73302,306,048
4Jul 15, 2023 06:426,289115,555,38551,570,57802,273,280
5Jul 15, 2023 06:426,63480,680,84747,345,0007,051,0002,441,216
6Jul 15, 2023 06:4220,843202,234,175157,922,00012,993,0002,445,312
7Jul 15, 2023 06:4220,885196,384,869163,243,0008,011,0002,420,736
8Jul 15, 2023 06:4220,896197,358,738163,328,0008,016,0002,363,392
9Jul 15, 2023 06:4220,901196,314,749162,370,0009,020,0002,359,296
10Jul 15, 2023 06:4220,907195,165,002163,417,0008,020,0002,527,232
11Jul 15, 2023 06:4221,060199,333,514167,705,0004,991,0002,527,232
12Jul 15, 2023 06:4221,063242,658,432172,720,08202,273,280