結果

問題 No.1219 Mancala Combo
ユーザー AEnAEn
提出日時 2022-05-18 11:44:20
言語 PyPy3
(7.3.15)
結果
AC  
実行時間 112 ms / 2,000 ms
コード長 209 bytes
コンパイル時間 956 ms
コンパイル使用メモリ 86,732 KB
実行使用メモリ 107,116 KB
最終ジャッジ日時 2023-10-14 18:35:43
合計ジャッジ時間 5,256 ms
ジャッジサーバーID
(参考情報)
judge12 / judge13
このコードへのチャレンジ
(要ログイン)

テストケース

テストケース表示
入力 結果 実行時間
実行使用メモリ
testcase_00 AC 59 ms
70,980 KB
testcase_01 AC 62 ms
71,340 KB
testcase_02 AC 62 ms
71,036 KB
testcase_03 AC 64 ms
71,272 KB
testcase_04 AC 63 ms
71,208 KB
testcase_05 AC 64 ms
71,152 KB
testcase_06 AC 65 ms
71,040 KB
testcase_07 AC 65 ms
71,320 KB
testcase_08 AC 64 ms
71,204 KB
testcase_09 AC 63 ms
71,320 KB
testcase_10 AC 65 ms
70,832 KB
testcase_11 AC 64 ms
70,800 KB
testcase_12 AC 61 ms
71,340 KB
testcase_13 AC 64 ms
71,316 KB
testcase_14 AC 64 ms
71,164 KB
testcase_15 AC 64 ms
71,104 KB
testcase_16 AC 65 ms
71,348 KB
testcase_17 AC 94 ms
95,876 KB
testcase_18 AC 100 ms
97,036 KB
testcase_19 AC 89 ms
93,332 KB
testcase_20 AC 103 ms
99,500 KB
testcase_21 AC 87 ms
91,068 KB
testcase_22 AC 91 ms
94,368 KB
testcase_23 AC 97 ms
101,624 KB
testcase_24 AC 93 ms
92,080 KB
testcase_25 AC 89 ms
93,196 KB
testcase_26 AC 96 ms
96,956 KB
testcase_27 AC 102 ms
105,300 KB
testcase_28 AC 112 ms
107,116 KB
権限があれば一括ダウンロードができます

ソースコード

diff #

N = int(input())
A = list(map(int, input().split()))

sm = 0
for i in reversed(range(N)):
    if (A[i]+sm) % (i+1) == 0:
        sm += (A[i]+sm)//(i+1)
    else:
        print('No')
        exit()
print('Yes')
0