結果

問題 No.1219 Mancala Combo
ユーザー もりをもりを
提出日時 2020-09-04 21:30:18
言語 Python3
(3.12.2 + numpy 1.26.4 + scipy 1.12.0)
結果
AC  
実行時間 192 ms / 2,000 ms
コード長 312 bytes
コンパイル時間 82 ms
コンパイル使用メモリ 10,640 KB
実行使用メモリ 30,920 KB
最終ジャッジ日時 2023-08-17 15:00:18
合計ジャッジ時間 2,731 ms
ジャッジサーバーID
(参考情報)
judge13 / judge11
このコードへのチャレンジ
(要ログイン)

テストケース

テストケース表示
入力 結果 実行時間
実行使用メモリ
testcase_00 AC 15 ms
7,748 KB
testcase_01 AC 15 ms
8,092 KB
testcase_02 AC 14 ms
7,788 KB
testcase_03 AC 15 ms
7,748 KB
testcase_04 AC 14 ms
7,780 KB
testcase_05 AC 15 ms
8,020 KB
testcase_06 AC 14 ms
7,812 KB
testcase_07 AC 15 ms
8,160 KB
testcase_08 AC 15 ms
7,748 KB
testcase_09 AC 15 ms
8,200 KB
testcase_10 AC 15 ms
7,860 KB
testcase_11 AC 15 ms
8,024 KB
testcase_12 AC 15 ms
7,784 KB
testcase_13 AC 14 ms
8,016 KB
testcase_14 AC 14 ms
8,148 KB
testcase_15 AC 14 ms
7,856 KB
testcase_16 AC 14 ms
7,920 KB
testcase_17 AC 53 ms
19,996 KB
testcase_18 AC 143 ms
24,460 KB
testcase_19 AC 50 ms
18,808 KB
testcase_20 AC 145 ms
24,712 KB
testcase_21 AC 46 ms
17,640 KB
testcase_22 AC 125 ms
22,628 KB
testcase_23 AC 64 ms
23,792 KB
testcase_24 AC 108 ms
20,348 KB
testcase_25 AC 49 ms
18,196 KB
testcase_26 AC 136 ms
23,872 KB
testcase_27 AC 71 ms
24,888 KB
testcase_28 AC 192 ms
30,920 KB
権限があれば一括ダウンロードができます

ソースコード

diff #

# URL : https://yukicoder.me/problems/no/1219
n = int(input())
a = list(map(int, input().split()))
mrg = 0
for i in range(n):
    idx = n - 1 - i
    need = n - i
    if (a[idx] + mrg) % need == 0:
        mrg += (a[idx] + mrg) // need
    elif a[idx] + mrg > 0:
        print('No')
        exit(0)
print('Yes')
0