結果

問題 No.1736 Princess vs. Dragoness
コンテスト
ユーザー Navier_Boltzmann
提出日時 2021-11-21 01:41:25
言語 Python3
(3.14.3 + numpy 2.4.4 + scipy 1.17.1)
コンパイル:
python3 -mpy_compile _filename_
実行:
python3 _filename_
結果
WA  
実行時間 -
コード長 289 bytes
記録
記録タグの例:
初AC ショートコード 純ショートコード 純主流ショートコード 最速実行時間
コンパイル時間 532 ms
コンパイル使用メモリ 20,952 KB
実行使用メモリ 15,616 KB
最終ジャッジ日時 2026-03-05 16:53:28
合計ジャッジ時間 7,899 ms
ジャッジサーバーID
(参考情報)
judge2 / judge3
このコードへのチャレンジ
(要ログイン)
ファイルパターン 結果
sample AC * 3
other AC * 26 WA * 8
権限があれば一括ダウンロードができます

ソースコード

diff #
raw source code

N,A,B,X,Y = map(int,input().split())
H = list(map(int,input().split()))
S = 0
res = A
cnt = 0
while res > 0 and cnt < N:
    tmp = H[cnt]
    nums = min(tmp//X,res)
    res -= nums
    H[cnt] -= nums*X
    cnt += 1
if sum(H) <= B*Y + res*X:
    print('Yes')
else:
    print('No')
    
    
0