結果
問題 | No.1736 Princess vs. Dragoness |
ユーザー |
|
提出日時 | 2021-11-12 21:44:02 |
言語 | PyPy3 (7.3.15) |
結果 |
WA
|
実行時間 | - |
コード長 | 300 bytes |
コンパイル時間 | 214 ms |
コンパイル使用メモリ | 82,076 KB |
実行使用メモリ | 73,404 KB |
最終ジャッジ日時 | 2024-11-25 17:44:45 |
合計ジャッジ時間 | 3,295 ms |
ジャッジサーバーID (参考情報) |
judge3 / judge4 |
(要ログイン)
ファイルパターン | 結果 |
---|---|
sample | AC * 3 |
other | AC * 23 WA * 10 |
ソースコード
import heapq N,A,B,X,Y = map(int,input().split()) H = list(map(int,input().split())) a = 0 H.sort(reverse=True) hq = H.copy() while a<A: h = heapq.heappop(hq) h-=X heapq.heappush(hq,h) a+=1 hq = list(map(lambda x:0 if x<=0 else x,list(hq))) print('Yes'if sum(hq)<=B*Y else 'No')