結果

問題 No.406 鴨等間隔の法則
ユーザー jamadjamad
提出日時 2017-07-23 16:40:07
言語 Python3
(3.12.2 + numpy 1.26.4 + scipy 1.12.0)
結果
AC  
実行時間 81 ms / 2,000 ms
コード長 131 bytes
コンパイル時間 92 ms
コンパイル使用メモリ 10,704 KB
実行使用メモリ 18,896 KB
最終ジャッジ日時 2023-09-21 18:32:53
合計ジャッジ時間 3,047 ms
ジャッジサーバーID
(参考情報)
judge13 / judge12
このコードへのチャレンジ
(要ログイン)

テストケース

テストケース表示
入力 結果 実行時間
実行使用メモリ
testcase_00 AC 42 ms
13,000 KB
testcase_01 AC 15 ms
7,824 KB
testcase_02 AC 15 ms
7,956 KB
testcase_03 AC 15 ms
7,972 KB
testcase_04 AC 77 ms
17,956 KB
testcase_05 AC 37 ms
12,448 KB
testcase_06 AC 38 ms
12,528 KB
testcase_07 AC 39 ms
12,448 KB
testcase_08 AC 75 ms
18,412 KB
testcase_09 AC 81 ms
18,724 KB
testcase_10 AC 42 ms
13,088 KB
testcase_11 AC 67 ms
16,560 KB
testcase_12 AC 48 ms
13,616 KB
testcase_13 AC 45 ms
12,900 KB
testcase_14 AC 71 ms
17,140 KB
testcase_15 AC 18 ms
8,748 KB
testcase_16 AC 20 ms
9,492 KB
testcase_17 AC 18 ms
8,552 KB
testcase_18 AC 19 ms
9,656 KB
testcase_19 AC 20 ms
9,048 KB
testcase_20 AC 22 ms
9,468 KB
testcase_21 AC 23 ms
10,228 KB
testcase_22 AC 29 ms
10,388 KB
testcase_23 AC 50 ms
13,664 KB
testcase_24 AC 60 ms
15,956 KB
testcase_25 AC 81 ms
18,852 KB
testcase_26 AC 78 ms
18,796 KB
testcase_27 AC 56 ms
18,812 KB
testcase_28 AC 59 ms
18,896 KB
testcase_29 AC 79 ms
18,816 KB
testcase_30 AC 77 ms
18,748 KB
testcase_31 AC 78 ms
18,480 KB
権限があれば一括ダウンロードができます

ソースコード

diff #

i=input
N=int(i())
X=sorted(map(int,i().split()))
Y={X[i+1]-X[i] for i in range(N-1)}
print(('NO','YES')[0 not in Y and len(Y)==1])
0