結果

問題 No.1736 Princess vs. Dragoness
ユーザー a aa a
提出日時 2022-10-07 15:55:41
言語 Python3
(3.12.2 + numpy 1.26.4 + scipy 1.12.0)
結果
WA  
実行時間 -
コード長 396 bytes
コンパイル時間 604 ms
コンパイル使用メモリ 10,816 KB
実行使用メモリ 8,728 KB
最終ジャッジ日時 2023-09-02 16:17:49
合計ジャッジ時間 14,300 ms
ジャッジサーバーID
(参考情報)
judge14 / judge11
このコードへのチャレンジ
(要ログイン)

テストケース

テストケース表示
入力 結果 実行時間
実行使用メモリ
testcase_00 AC 17 ms
8,040 KB
testcase_01 WA -
testcase_02 AC 16 ms
7,932 KB
testcase_03 WA -
testcase_04 AC 57 ms
7,956 KB
testcase_05 AC 19 ms
7,896 KB
testcase_06 AC 806 ms
7,952 KB
testcase_07 AC 203 ms
8,536 KB
testcase_08 AC 84 ms
7,968 KB
testcase_09 AC 156 ms
8,624 KB
testcase_10 AC 16 ms
8,040 KB
testcase_11 WA -
testcase_12 WA -
testcase_13 AC 1,294 ms
8,432 KB
testcase_14 WA -
testcase_15 AC 259 ms
7,908 KB
testcase_16 AC 445 ms
7,924 KB
testcase_17 WA -
testcase_18 AC 1,542 ms
8,540 KB
testcase_19 AC 1,674 ms
8,392 KB
testcase_20 AC 233 ms
7,900 KB
testcase_21 WA -
testcase_22 AC 147 ms
8,588 KB
testcase_23 AC 64 ms
8,540 KB
testcase_24 AC 56 ms
8,044 KB
testcase_25 AC 52 ms
8,036 KB
testcase_26 AC 115 ms
8,464 KB
testcase_27 AC 80 ms
8,540 KB
testcase_28 AC 98 ms
8,508 KB
testcase_29 AC 107 ms
8,372 KB
testcase_30 AC 370 ms
8,468 KB
testcase_31 AC 98 ms
8,040 KB
testcase_32 AC 208 ms
8,368 KB
testcase_33 WA -
testcase_34 WA -
testcase_35 WA -
権限があれば一括ダウンロードができます

ソースコード

diff #

import math
n,a,b,x,y=list(map(int,input().split()))
h=list(map(int,input().split ()))
for k in range(a):
    mi=h.index(max(h))
    h[mi]-=x
for i in range(b):
    p=y
    for j in range(n):
        d=min(p,h[j])
        p-=d
        h[j]-=d
        if p==0<h[j]:
            break
    if i==b-1 and h[-1]>0:
        print("No")
        break
    if max(h)<=0:
        print("Yes")
        break
0