結果
| 問題 |
No.23 技の選択
|
| コンテスト | |
| ユーザー |
|
| 提出日時 | 2022-10-22 05:59:18 |
| 言語 | C++17 (gcc 13.3.0 + boost 1.87.0) |
| 結果 |
WA
|
| 実行時間 | - |
| コード長 | 409 bytes |
| コンパイル時間 | 1,690 ms |
| コンパイル使用メモリ | 192,316 KB |
| 最終ジャッジ日時 | 2025-02-08 11:00:30 |
|
ジャッジサーバーID (参考情報) |
judge3 / judge3 |
(要ログイン)
| ファイルパターン | 結果 |
|---|---|
| other | AC * 17 WA * 16 |
ソースコード
#include <bits/stdc++.h>
#define rep(i,n) for(int i = 0; i < (n); i++)
using namespace std;
using ll = long long;
using ld = long double;
int main(){
cin.tie(0);
ios::sync_with_stdio(0);
int H,A,D; cin >> H >> A >> D;
ld ans = 1e18;
for(int a = 0; a * A <= H; a++) {
int R = H - a * A;
ans = min(ans, ld(a + 1.5 * ((R + D - 1) / D)));
}
cout << ans << endl;
}