結果

問題 No.1134 Deviation Score Ⅱ
ユーザー 双六双六
提出日時 2020-08-19 01:47:25
言語 PyPy3
(7.3.15)
結果
WA  
実行時間 -
コード長 733 bytes
コンパイル時間 417 ms
コンパイル使用メモリ 82,400 KB
実行使用メモリ 81,024 KB
最終ジャッジ日時 2024-04-20 08:06:22
合計ジャッジ時間 3,168 ms
ジャッジサーバーID
(参考情報)
judge1 / judge2
このコードへのチャレンジ
(要ログイン)

テストケース

テストケース表示
入力 結果 実行時間
実行使用メモリ
testcase_00 AC 48 ms
53,632 KB
testcase_01 AC 71 ms
77,696 KB
testcase_02 AC 68 ms
72,832 KB
testcase_03 AC 71 ms
75,904 KB
testcase_04 AC 59 ms
67,456 KB
testcase_05 AC 71 ms
77,696 KB
testcase_06 AC 58 ms
65,024 KB
testcase_07 AC 57 ms
63,744 KB
testcase_08 AC 68 ms
75,648 KB
testcase_09 AC 56 ms
63,616 KB
testcase_10 AC 54 ms
60,928 KB
testcase_11 AC 66 ms
72,576 KB
testcase_12 AC 64 ms
71,424 KB
testcase_13 AC 73 ms
79,616 KB
testcase_14 AC 60 ms
72,576 KB
testcase_15 AC 62 ms
68,224 KB
testcase_16 AC 58 ms
64,256 KB
testcase_17 AC 64 ms
71,680 KB
testcase_18 AC 66 ms
72,832 KB
testcase_19 AC 68 ms
76,032 KB
testcase_20 AC 62 ms
69,248 KB
testcase_21 AC 69 ms
76,160 KB
testcase_22 AC 68 ms
75,008 KB
testcase_23 AC 46 ms
53,760 KB
testcase_24 AC 46 ms
53,504 KB
testcase_25 WA -
testcase_26 WA -
testcase_27 AC 47 ms
53,504 KB
権限があれば一括ダウンロードができます

ソースコード

diff #

# import sys; input = sys.stdin.buffer.readline
# sys.setrecursionlimit(10**7)
from collections import defaultdict
con = 10 ** 9 + 7; INF = float("inf")

def getlist():
	return list(map(int, input().split()))

#処理内容
def main():
	N = int(input())
	X = getlist()
	M = int(input())
	ave = sum(X) / N
	s2 = 0
	for i in range(N):
		s2 += (X[i] - ave) ** 2

	if s2 == 0:
		print(50)
		return
	s = (s2 / N) ** 0.5
	# print(ave, s2, s)


	ans = 50 + (X[M - 1] - ave) * 10 / s
	if ans >= 0:
		print(int(ans // 1))
	else:
		ans2 = -int(abs(ans) // 1)
		print(ans)


	# if X[M - 1] >= ave:
	# 	dif = int()
	# 	print(50 + dif)
	# else:
	# 	dif = int((ave - X[M - 1]) * 10 // s)
	# 	print(50 - dif)





if __name__ == '__main__':
	main()
0