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 listJan 10, 2025 08:07Ian MckibbenIan MckibbenError
Source Code

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

Challenge History

No challenges yet.

Run Statistics
#DateScoreWall TimeCPU UserCPU SystemMemoryError
1Jan 10, 2025 08:0700000Error: No answer to stdout. Died or killed?
2Jan 10, 2025 08:0749,350432,546,702387,687,00016,986,0002,363,392
3Jan 10, 2025 08:0749,648432,277,130387,110,00020,005,0002,437,120
4Jan 10, 2025 08:0749,760433,465,306390,030,00018,001,0002,322,432
5Jan 10, 2025 08:0749,910440,291,817397,255,00012,007,0002,400,256
6Jan 10, 2025 08:0750,804443,082,635398,568,00018,025,0002,371,584
7Jan 10, 2025 08:0750,896446,971,487400,330,00017,014,0002,265,088
8Jan 10, 2025 08:0751,433447,274,907402,764,00018,988,0002,519,040
9Jan 10, 2025 08:0751,436448,361,581402,785,00018,989,0002,367,488
10Jan 10, 2025 08:0752,017453,529,137405,561,00020,977,0002,269,184