fork download
  1. #!/usr/bin/env python3
  2. from statistics import median_high
  3.  
  4. if __name__ == '__main__':
  5. n = int(input())
  6. a = [int(x) for x in input().split(' ')[:n]]
  7. print(median_high([median_high(k)
  8. for k in sum([[a[j: i + j + 1]
  9. for j in range(n) if i + j < n]
  10. for i in range(n)], [])]))
  11.  
Runtime error #stdin #stdout #stderr 0.15s 26596KB
stdin
Standard input is empty
stdout
Standard output is empty
stderr
Traceback (most recent call last):
  File "./prog.py", line 5, in <module>
EOFError: EOF when reading a line