結果

問題 No.842 初詣
ユーザー nohakai3nohakai3
提出日時 2022-07-26 11:26:02
言語 Python3
(3.12.2 + numpy 1.26.4 + scipy 1.12.0)
結果
AC  
実行時間 202 ms / 2,000 ms
コード長 395 bytes
コンパイル時間 254 ms
コンパイル使用メモリ 10,716 KB
実行使用メモリ 23,168 KB
最終ジャッジ日時 2023-09-23 04:12:48
合計ジャッジ時間 2,463 ms
ジャッジサーバーID
(参考情報)
judge15 / judge12
このコードへのチャレンジ
(要ログイン)

テストケース

テストケース表示
入力 結果 実行時間
実行使用メモリ
testcase_00 AC 15 ms
7,740 KB
testcase_01 AC 16 ms
7,672 KB
testcase_02 AC 15 ms
7,672 KB
testcase_03 AC 39 ms
9,800 KB
testcase_04 AC 29 ms
9,008 KB
testcase_05 AC 92 ms
13,952 KB
testcase_06 AC 17 ms
7,796 KB
testcase_07 AC 51 ms
9,796 KB
testcase_08 AC 17 ms
7,848 KB
testcase_09 AC 35 ms
9,396 KB
testcase_10 AC 202 ms
23,168 KB
testcase_11 AC 15 ms
7,848 KB
testcase_12 AC 53 ms
10,984 KB
testcase_13 AC 29 ms
9,148 KB
testcase_14 AC 21 ms
8,556 KB
testcase_15 AC 17 ms
7,740 KB
testcase_16 AC 23 ms
8,540 KB
testcase_17 AC 38 ms
9,828 KB
testcase_18 AC 85 ms
13,788 KB
testcase_19 AC 40 ms
9,120 KB
testcase_20 AC 80 ms
13,288 KB
権限があれば一括ダウンロードができます

ソースコード

diff #

a,b,c,d,e,f,g=map(int,input().split())

q=[]
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+n
                        q.append(x)
                        
if g in q:
    print("YES")
else:
    print("NO")
0