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 listNov 26, 2022 17:20Bernard TeoBernard TeoError
Source Code

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

Challenge History

No challenges yet.

Run Statistics
#DateScoreWall TimeCPU UserCPU SystemMemoryError
1Nov 26, 2022 17:2000000Error: expected "2076874931 ", got "1"
2Nov 26, 2022 17:2000000Error: expected "2009763423 ", got "1"
3Nov 26, 2022 17:2000000Error: expected "1915631095 ", got "1"
4Nov 26, 2022 17:2000000Error: expected "2144150465 ", got "2"
5Nov 26, 2022 17:2000000Error: expected "2257561349 ", got "1"
6Nov 26, 2022 17:2100000Error: expected "2074225994 ", got "1"
7Nov 26, 2022 17:2100000Error: expected "2218477306 ", got "1"
8Nov 26, 2022 17:2100000Error: expected "2234272173 ", got "1"
9Nov 26, 2022 17:2300000Error: expected "2181131078 ", got "2"
10Nov 26, 2022 17:2300000Error: expected "2226266461 ", got "1"
11Nov 26, 2022 17:214,33190,337,43935,513,42102,207,744
12Nov 26, 2022 17:214,332102,260,14035,518,91202,240,512
13Nov 26, 2022 17:214,459115,283,96136,561,20302,203,648