結果

問題 No.842 初詣
ユーザー brthyyjpbrthyyjp
提出日時 2020-05-21 04:37:48
言語 PyPy3
(7.3.15)
結果
AC  
実行時間 54 ms / 2,000 ms
コード長 425 bytes
コンパイル時間 358 ms
コンパイル使用メモリ 82,312 KB
実行使用メモリ 68,372 KB
最終ジャッジ日時 2024-04-09 23:14:49
合計ジャッジ時間 2,105 ms
ジャッジサーバーID
(参考情報)
judge4 / judge1
このコードへのチャレンジ
(要ログイン)

テストケース

テストケース表示
入力 結果 実行時間
実行使用メモリ
testcase_00 AC 33 ms
52,644 KB
testcase_01 AC 32 ms
53,280 KB
testcase_02 AC 32 ms
52,992 KB
testcase_03 AC 45 ms
64,040 KB
testcase_04 AC 50 ms
64,360 KB
testcase_05 AC 52 ms
65,908 KB
testcase_06 AC 40 ms
61,496 KB
testcase_07 AC 50 ms
66,880 KB
testcase_08 AC 41 ms
60,212 KB
testcase_09 AC 49 ms
64,932 KB
testcase_10 AC 54 ms
68,372 KB
testcase_11 AC 33 ms
52,532 KB
testcase_12 AC 39 ms
62,136 KB
testcase_13 AC 46 ms
63,584 KB
testcase_14 AC 43 ms
61,780 KB
testcase_15 AC 41 ms
61,156 KB
testcase_16 AC 44 ms
62,236 KB
testcase_17 AC 38 ms
60,940 KB
testcase_18 AC 39 ms
61,124 KB
testcase_19 AC 46 ms
65,768 KB
testcase_20 AC 50 ms
65,368 KB
権限があれば一括ダウンロードができます

ソースコード

diff #

a, b, c, d, e, f, g = map(int, input().split())
for i in range(a+1):
    for j in range(b+1):
        for k in range(c+1):
            for l in range(d+1):
                for m in range(e+1):
                    for n in range(f+1):
                        x = 500*i+100*j+50*k+10*l+5*m+1*n
                        if x == g:
                            print('YES')
                            exit()
else:
    print('NO')
0