結果
問題 | No.1015 おつりは要らないです |
ユーザー | setsuna |
提出日時 | 2020-06-25 15:47:05 |
言語 | Python3 (3.12.2 + numpy 1.26.4 + scipy 1.12.0) |
結果 |
WA
|
実行時間 | - |
コード長 | 426 bytes |
コンパイル時間 | 111 ms |
コンパイル使用メモリ | 10,824 KB |
実行使用メモリ | 18,828 KB |
最終ジャッジ日時 | 2023-09-16 22:44:14 |
合計ジャッジ時間 | 8,796 ms |
ジャッジサーバーID (参考情報) |
judge15 / judge13 |
(要ログイン)
テストケース
テストケース表示入力 | 結果 | 実行時間 実行使用メモリ |
---|---|---|
testcase_00 | AC | 16 ms
7,744 KB |
testcase_01 | AC | 17 ms
8,124 KB |
testcase_02 | AC | 17 ms
8,244 KB |
testcase_03 | AC | 16 ms
7,916 KB |
testcase_04 | WA | - |
testcase_05 | WA | - |
testcase_06 | AC | 16 ms
7,872 KB |
testcase_07 | AC | 16 ms
8,188 KB |
testcase_08 | AC | 16 ms
8,184 KB |
testcase_09 | AC | 16 ms
8,196 KB |
testcase_10 | WA | - |
testcase_11 | WA | - |
testcase_12 | WA | - |
testcase_13 | WA | - |
testcase_14 | WA | - |
testcase_15 | AC | 213 ms
18,100 KB |
testcase_16 | AC | 224 ms
18,632 KB |
testcase_17 | AC | 226 ms
18,816 KB |
testcase_18 | AC | 222 ms
18,388 KB |
testcase_19 | AC | 217 ms
18,480 KB |
testcase_20 | WA | - |
testcase_21 | WA | - |
testcase_22 | WA | - |
testcase_23 | WA | - |
testcase_24 | WA | - |
testcase_25 | WA | - |
testcase_26 | WA | - |
testcase_27 | WA | - |
testcase_28 | WA | - |
testcase_29 | WA | - |
testcase_30 | AC | 16 ms
8,188 KB |
testcase_31 | AC | 163 ms
9,960 KB |
testcase_32 | AC | 163 ms
10,056 KB |
testcase_33 | AC | 86 ms
18,800 KB |
testcase_34 | WA | - |
testcase_35 | AC | 16 ms
7,920 KB |
testcase_36 | AC | 17 ms
7,828 KB |
ソースコード
N, X, Y, Z = map(int, input().split()) A = [x // 1000 + 1 for x in list(map(int, input().split()))] for i in range(N): x, y, z = A[i], 0, 0 if x > X: y = (x - X) // 5 + int((x - X) % 5 != 0) x = max(x - y * 5, 0) if y > Y: z = (y - Y) // 2 + int((y - Y) % 2 != 0) y = max(y - z * 2, 0) if z > Z: print('No') exit() X -= x Y -= y Z -= z print('Yes')