結果

問題 No.406 鴨等間隔の法則
ユーザー compass19compass19
提出日時 2016-11-26 10:53:36
言語 Python3
(3.11.6 + numpy 1.26.0 + scipy 1.11.3)
結果
AC  
実行時間 87 ms / 2,000 ms
コード長 202 bytes
コンパイル時間 392 ms
コンパイル使用メモリ 10,680 KB
実行使用メモリ 18,944 KB
最終ジャッジ日時 2023-09-21 18:20:28
合計ジャッジ時間 3,079 ms
ジャッジサーバーID
(参考情報)
judge15 / judge12
このコードへのチャレンジ(β)

テストケース

テストケース表示
入力 結果 実行時間
実行使用メモリ
testcase_00 AC 34 ms
12,520 KB
testcase_01 AC 15 ms
7,864 KB
testcase_02 AC 15 ms
8,124 KB
testcase_03 AC 14 ms
8,092 KB
testcase_04 AC 61 ms
17,892 KB
testcase_05 AC 30 ms
11,860 KB
testcase_06 AC 31 ms
12,020 KB
testcase_07 AC 34 ms
12,288 KB
testcase_08 AC 61 ms
18,320 KB
testcase_09 AC 64 ms
18,848 KB
testcase_10 AC 35 ms
12,540 KB
testcase_11 AC 53 ms
16,520 KB
testcase_12 AC 41 ms
13,548 KB
testcase_13 AC 37 ms
13,028 KB
testcase_14 AC 73 ms
17,144 KB
testcase_15 AC 16 ms
8,720 KB
testcase_16 AC 17 ms
8,912 KB
testcase_17 AC 16 ms
8,504 KB
testcase_18 AC 16 ms
8,904 KB
testcase_19 AC 19 ms
9,044 KB
testcase_20 AC 21 ms
9,552 KB
testcase_21 AC 19 ms
9,600 KB
testcase_22 AC 29 ms
10,488 KB
testcase_23 AC 40 ms
13,840 KB
testcase_24 AC 66 ms
15,788 KB
testcase_25 AC 65 ms
18,880 KB
testcase_26 AC 87 ms
18,944 KB
testcase_27 AC 45 ms
18,780 KB
testcase_28 AC 44 ms
18,792 KB
testcase_29 AC 87 ms
18,848 KB
testcase_30 AC 84 ms
18,764 KB
testcase_31 AC 62 ms
18,572 KB
権限があれば一括ダウンロードができます

ソースコード

diff #

input()
x = sorted(list(map(int, input().split())))
distance = x[0] - x[1]
if distance == 0: print('NO'); exit()
for i in range(len(x)-1):
	if x[i] - x[i+1] != distance: print('NO'); exit()
print('YES')
0