結果

問題 No.406 鴨等間隔の法則
ユーザー ThetaTheta
提出日時 2022-10-30 13:14:07
言語 Python3
(3.12.2 + numpy 1.26.4 + scipy 1.12.0)
結果
WA  
実行時間 -
コード長 253 bytes
コンパイル時間 67 ms
コンパイル使用メモリ 10,540 KB
実行使用メモリ 40,388 KB
最終ジャッジ日時 2023-09-21 11:31:35
合計ジャッジ時間 10,259 ms
ジャッジサーバーID
(参考情報)
judge15 / judge11
このコードへのチャレンジ
(要ログイン)

テストケース

テストケース表示
入力 結果 実行時間
実行使用メモリ
testcase_00 AC 152 ms
34,104 KB
testcase_01 AC 128 ms
29,596 KB
testcase_02 AC 127 ms
29,520 KB
testcase_03 WA -
testcase_04 AC 186 ms
39,280 KB
testcase_05 AC 148 ms
34,116 KB
testcase_06 AC 149 ms
34,304 KB
testcase_07 AC 150 ms
34,376 KB
testcase_08 AC 189 ms
39,880 KB
testcase_09 AC 197 ms
40,152 KB
testcase_10 AC 155 ms
33,808 KB
testcase_11 AC 179 ms
37,848 KB
testcase_12 AC 161 ms
34,960 KB
testcase_13 AC 157 ms
34,396 KB
testcase_14 AC 182 ms
38,516 KB
testcase_15 WA -
testcase_16 AC 130 ms
30,856 KB
testcase_17 AC 127 ms
30,304 KB
testcase_18 AC 130 ms
30,976 KB
testcase_19 AC 129 ms
30,496 KB
testcase_20 AC 131 ms
30,952 KB
testcase_21 AC 131 ms
31,500 KB
testcase_22 AC 136 ms
31,924 KB
testcase_23 AC 158 ms
35,136 KB
testcase_24 AC 174 ms
37,292 KB
testcase_25 AC 189 ms
40,256 KB
testcase_26 AC 189 ms
40,240 KB
testcase_27 WA -
testcase_28 AC 170 ms
40,268 KB
testcase_29 AC 194 ms
40,328 KB
testcase_30 AC 192 ms
40,264 KB
testcase_31 AC 190 ms
39,828 KB
権限があれば一括ダウンロードができます

ソースコード

diff #

from numpy import diff


def main():
    N = int(input())
    x = list(map(int, input().split()))
    x.sort()
    x_diff = diff(x)
    if len(set(x_diff)) == 1:
        print("YES")
    else:
        print("NO")


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