結果
問題 | No.275 中央値を求めよ |
ユーザー |
![]() |
提出日時 | 2017-06-15 15:28:19 |
言語 | Python2 (2.7.18) |
結果 |
AC
|
実行時間 | 13 ms / 1,000 ms |
コード長 | 153 bytes |
コンパイル時間 | 250 ms |
コンパイル使用メモリ | 7,040 KB |
実行使用メモリ | 6,400 KB |
最終ジャッジ日時 | 2024-06-25 00:32:14 |
合計ジャッジ時間 | 1,766 ms |
ジャッジサーバーID (参考情報) |
judge4 / judge2 |
(要ログイン)
ファイルパターン | 結果 |
---|---|
sample | AC * 3 |
other | AC * 38 |
ソースコード
N=raw_input()A=raw_input()L=map(int, A.split())L.sort()if len(L)%2==0:print float(L[(int(N)/2)-1]+L[int(N)/2])/2else:print L[(int(N)/2)]