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 16, 2024 01:32zielajzielajScore: 3,518Success
Source Code

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

Challenge History

No challenges yet.

Run Statistics
#DateScoreWall TimeCPU UserCPU SystemMemoryError
1Oct 16, 2024 01:323,48150,335,53427,523,0001,019,0002,453,504
2Oct 16, 2024 01:323,48856,325,35928,603,00002,367,488
3Oct 16, 2024 01:323,49957,079,75227,664,0001,024,0002,396,160
4Oct 16, 2024 01:323,49959,757,39628,690,00002,334,720
5Oct 16, 2024 01:323,51857,479,24925,866,0002,984,0002,310,144
6Oct 16, 2024 01:323,51956,963,99025,872,0002,985,0002,400,256
7Oct 16, 2024 01:323,51958,317,02827,862,000995,0002,478,080
8Oct 16, 2024 01:323,52056,598,44227,872,000995,0002,514,944
9Oct 16, 2024 01:323,52451,864,16826,830,0002,063,0002,326,528