結果

問題 No.1134 Deviation Score Ⅱ
ユーザー akitsugu777akitsugu777
提出日時 2020-12-07 14:57:06
言語 Python3
(3.12.2 + numpy 1.26.4 + scipy 1.12.0)
結果
AC  
実行時間 71 ms / 2,000 ms
コード長 254 bytes
コンパイル時間 294 ms
コンパイル使用メモリ 11,928 KB
実行使用メモリ 18,948 KB
最終ジャッジ日時 2023-10-17 16:30:49
合計ジャッジ時間 2,721 ms
ジャッジサーバーID
(参考情報)
judge15 / judge11
このコードへのチャレンジ
(要ログイン)

テストケース

テストケース表示
入力 結果 実行時間
実行使用メモリ
testcase_00 AC 28 ms
10,212 KB
testcase_01 AC 68 ms
16,644 KB
testcase_02 AC 54 ms
14,648 KB
testcase_03 AC 60 ms
15,904 KB
testcase_04 AC 42 ms
12,592 KB
testcase_05 AC 66 ms
16,616 KB
testcase_06 AC 37 ms
11,836 KB
testcase_07 AC 35 ms
11,416 KB
testcase_08 AC 59 ms
15,584 KB
testcase_09 AC 33 ms
11,324 KB
testcase_10 AC 28 ms
10,344 KB
testcase_11 AC 52 ms
14,652 KB
testcase_12 AC 52 ms
14,240 KB
testcase_13 AC 71 ms
17,412 KB
testcase_14 AC 54 ms
14,688 KB
testcase_15 AC 44 ms
13,132 KB
testcase_16 AC 35 ms
11,532 KB
testcase_17 AC 52 ms
14,400 KB
testcase_18 AC 57 ms
14,684 KB
testcase_19 AC 63 ms
16,016 KB
testcase_20 AC 47 ms
13,288 KB
testcase_21 AC 59 ms
16,572 KB
testcase_22 AC 53 ms
13,476 KB
testcase_23 AC 28 ms
10,160 KB
testcase_24 AC 28 ms
10,160 KB
testcase_25 AC 32 ms
11,096 KB
testcase_26 AC 71 ms
18,948 KB
testcase_27 AC 28 ms
10,212 KB
権限があれば一括ダウンロードができます

ソースコード

diff #

N = int(input())
X = list(map(int, input().split()))
M = int(input())

Ans = 0
A = sum(X) / N
A2 = (sum([(i-A)**2 for i in X]) / N)**0.5
if A2 == 0:
    Ans = 50
else:
    A3 = (abs(A-X[M-1])*10) / A2
    Ans = 50 + [-A3, A3][X[M-1] > A]

print(int(Ans))
0