結果
| 問題 | No.3681 心の沸騰石 |
| コンテスト | |
| ユーザー |
Tuchmos
|
| 提出日時 | 2026-09-05 13:39:54 |
| 言語 | PyPy3 (8.0.0 + ACL) |
| 結果 |
WA
不安定
(最新)
AC
(最初)
|
| 実行時間 | - |
| コード長 | 279 bytes |
| 記録 | |
| コンパイル時間 | 89 ms |
| コンパイル使用メモリ | 65,064 KB |
| 実行使用メモリ | 53,760 KB |
| 最終ジャッジ日時 | 2026-10-17 03:49:47 |
| 合計ジャッジ時間 | 2,007 ms |
|
ジャッジサーバーID (参考情報) |
judge2_0 / judge1_0 |
(要ログイン)
| ファイルパターン | 結果 |
|---|---|
| sample | AC * 4 |
| other | AC * 13 WA * 1 |
ソースコード
R,P,Q=map(int,input().split())
A,B,C,D=map(int,input().split())
ok=0
ng=10**18
while ng-ok>1:
X=(ok+ng)//2
pls=max(0,X-A)+max(0,X-B)+max(0,X-C)
if pls>D:
ng=X
continue
need=Q*pls+X*P
if need<=R:
ok=X
else:
ng=X
print(ok)
Tuchmos