結果
| 問題 |
No.1739 Princess vs. Dragoness (& AoE)
|
| コンテスト | |
| ユーザー |
|
| 提出日時 | 2021-11-12 22:19:58 |
| 言語 | PyPy3 (7.3.15) |
| 結果 |
WA
|
| 実行時間 | - |
| コード長 | 335 bytes |
| コンパイル時間 | 248 ms |
| コンパイル使用メモリ | 82,304 KB |
| 実行使用メモリ | 97,920 KB |
| 最終ジャッジ日時 | 2024-11-25 19:20:48 |
| 合計ジャッジ時間 | 5,807 ms |
|
ジャッジサーバーID (参考情報) |
judge3 / judge1 |
(要ログイン)
| ファイルパターン | 結果 |
|---|---|
| sample | WA * 3 |
| other | WA * 40 |
ソースコード
from heapq import heappop,heappush
N,A,B,X,Y = map(int,input().split())
H = list(map(int,input().split()))
q = []
for h in H:
heappush(q,-h)
while A and q:
h = heappop(q)
h *= -1
if h > X:
heappush(q,-(h-X))
A -=1
SUMS = 0
for h in q:
SUMS += -h
if SUMS <= Y * B:
print('Yes')
else:
print('No')