結果

問題 No.2451 Redistribute Integers
ユーザー minimumminimum
提出日時 2023-09-01 21:27:02
言語 PyPy3
(7.3.15)
結果
WA  
実行時間 -
コード長 215 bytes
コンパイル時間 271 ms
コンパイル使用メモリ 87,332 KB
実行使用メモリ 234,604 KB
最終ジャッジ日時 2023-09-01 21:27:12
合計ジャッジ時間 4,676 ms
ジャッジサーバーID
(参考情報)
judge14 / judge12
このコードへのチャレンジ
(要ログイン)

テストケース

テストケース表示
入力 結果 実行時間
実行使用メモリ
testcase_00 AC 76 ms
71,332 KB
testcase_01 AC 71 ms
71,396 KB
testcase_02 AC 71 ms
71,620 KB
testcase_03 AC 72 ms
71,588 KB
testcase_04 WA -
testcase_05 WA -
testcase_06 WA -
testcase_07 WA -
testcase_08 AC 215 ms
234,604 KB
testcase_09 AC 71 ms
71,396 KB
testcase_10 WA -
testcase_11 WA -
testcase_12 AC 134 ms
102,196 KB
testcase_13 WA -
testcase_14 WA -
testcase_15 WA -
testcase_16 AC 155 ms
127,416 KB
testcase_17 AC 192 ms
167,668 KB
testcase_18 WA -
testcase_19 AC 87 ms
83,244 KB
testcase_20 AC 202 ms
179,036 KB
testcase_21 AC 235 ms
163,972 KB
権限があれば一括ダウンロードができます

ソースコード

diff #

N = int(input())
if N == 2:
    print("Yes")
    exit()
A = list(map(int, input().split()))
B = set([A[i] % (N - 2) for i in range(N)])
if sum(A) % N == 0 and len(B) == 1:
    print("Yes")
else:
    print("No")
    
0