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 17, 2024 01:02zielajzielajScore: 3,396Success
Source Code

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

Challenge History

No challenges yet.

Run Statistics
#DateScoreWall TimeCPU UserCPU SystemMemoryError
1Oct 17, 2024 01:023,36355,278,11326,556,0001,021,0002,424,832
2Oct 17, 2024 01:023,36752,253,70827,612,00002,285,568
3Oct 17, 2024 01:023,37553,537,05126,647,0001,024,0002,437,120
4Oct 17, 2024 01:023,39651,376,60026,850,000994,0002,482,176
5Oct 17, 2024 01:023,39653,932,20524,863,0002,983,0002,269,184
6Oct 17, 2024 01:023,39754,381,33226,860,000994,0002,387,968
7Oct 17, 2024 01:023,39755,658,95725,866,0001,989,0002,449,408
8Oct 17, 2024 01:023,39751,628,13825,869,0001,989,0002,416,640
9Oct 17, 2024 01:023,40150,290,53825,900,0001,992,0002,289,664