結果

問題 No.1736 Princess vs. Dragoness
ユーザー kohei2019kohei2019
提出日時 2023-06-11 23:53:07
言語 PyPy3
(7.3.15)
結果
AC  
実行時間 110 ms / 2,000 ms
コード長 348 bytes
コンパイル時間 633 ms
コンパイル使用メモリ 87,092 KB
実行使用メモリ 78,160 KB
最終ジャッジ日時 2023-09-01 03:21:04
合計ジャッジ時間 6,066 ms
ジャッジサーバーID
(参考情報)
judge13 / judge12
このコードへのチャレンジ
(要ログイン)

テストケース

テストケース表示
入力 結果 実行時間
実行使用メモリ
testcase_00 AC 74 ms
71,400 KB
testcase_01 AC 71 ms
71,476 KB
testcase_02 AC 75 ms
71,608 KB
testcase_03 AC 83 ms
75,660 KB
testcase_04 AC 91 ms
76,828 KB
testcase_05 AC 82 ms
76,068 KB
testcase_06 AC 95 ms
76,896 KB
testcase_07 AC 107 ms
78,160 KB
testcase_08 AC 97 ms
77,668 KB
testcase_09 AC 108 ms
78,076 KB
testcase_10 AC 79 ms
75,872 KB
testcase_11 AC 110 ms
78,004 KB
testcase_12 AC 91 ms
76,780 KB
testcase_13 AC 97 ms
77,068 KB
testcase_14 AC 93 ms
76,784 KB
testcase_15 AC 86 ms
76,788 KB
testcase_16 AC 96 ms
76,752 KB
testcase_17 AC 99 ms
76,868 KB
testcase_18 AC 88 ms
76,776 KB
testcase_19 AC 92 ms
76,488 KB
testcase_20 AC 83 ms
75,648 KB
testcase_21 AC 106 ms
77,492 KB
testcase_22 AC 105 ms
78,100 KB
testcase_23 AC 98 ms
76,700 KB
testcase_24 AC 78 ms
71,448 KB
testcase_25 AC 107 ms
77,396 KB
testcase_26 AC 97 ms
77,588 KB
testcase_27 AC 102 ms
77,684 KB
testcase_28 AC 87 ms
76,844 KB
testcase_29 AC 82 ms
76,356 KB
testcase_30 AC 91 ms
76,612 KB
testcase_31 AC 103 ms
77,520 KB
testcase_32 AC 105 ms
77,764 KB
testcase_33 AC 73 ms
71,664 KB
testcase_34 AC 73 ms
71,640 KB
testcase_35 AC 76 ms
71,460 KB
権限があれば一括ダウンロードができます

ソースコード

diff #

import heapq
N,A,B,X,Y = map(int,input().split())
lsH = list(map(lambda x:-int(x),input().split()))
heapq.heapify(lsH)

for i in range(A):
    hp = heapq.heappop(lsH)
    v = hp + X
    heapq.heappush(lsH, v)

vsum = 0
for j in lsH:
    if j >= 0:
        continue
    else:
        vsum -= j

if vsum > B*Y:
    print('No')
else:
    print('Yes')
0