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 2, 2026 06:11Rajarshi BasuRajarshi BasuScore: 85,995Success
Source Code

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

Challenge History

No challenges yet.

Run Statistics
#DateScoreWall TimeCPU UserCPU SystemMemoryError
1Jan 2, 2026 06:115,07169,799,70139,553,0002,028,0002,478,080
2Jan 2, 2026 06:115,34273,737,44241,811,0001,991,0002,367,488
3Jan 2, 2026 06:115,59372,463,55344,866,000997,0002,510,848
4Jan 2, 2026 06:115,62479,744,17638,097,0008,020,0002,433,024
5Jan 2, 2026 06:115,68879,235,33141,570,0005,069,0002,510,848
6Jan 2, 2026 06:115,76971,536,91744,288,0003,019,0002,449,408
7Jan 2, 2026 06:115,78476,987,89239,353,0008,072,0002,371,584
8Jan 2, 2026 06:115,83172,795,45441,838,0005,976,0002,400,256
9Jan 2, 2026 06:115,85575,838,28545,007,0003,000,0002,441,216
10Jan 2, 2026 06:1181,887696,106,327545,570,000125,900,0002,441,216
11Jan 2, 2026 06:1184,893719,725,989584,266,000111,859,0002,281,472
12Jan 2, 2026 06:1185,300721,756,615570,559,000128,900,0002,387,968
13Jan 2, 2026 06:1185,995733,682,227577,310,000127,847,0002,441,216
14Jan 2, 2026 06:1187,066739,824,241592,953,000120,990,0002,424,832
15Jan 2, 2026 06:1187,267740,443,981591,663,000123,929,0002,527,232
16Jan 2, 2026 06:1188,142749,988,318608,801,000113,962,0002,490,368
17Jan 2, 2026 06:1190,283772,133,877615,437,000124,885,0002,318,336
18Jan 2, 2026 06:1191,741778,122,869626,395,000125,878,0002,494,464
19Jan 2, 2026 06:1192,415786,111,912637,994,000119,811,0002,424,832
20Jan 2, 2026 06:1193,610796,700,306652,664,000114,940,0002,387,968
21Jan 2, 2026 06:1195,328807,552,077656,741,000124,950,0002,498,560
22Jan 2, 2026 06:11102,377867,624,595738,551,000100,938,0002,281,472
23Jan 2, 2026 06:11105,926893,739,371750,646,000117,944,0002,465,792
24Jan 2, 2026 06:11110,980938,982,029788,165,000121,870,0002,412,544