結果
問題 | No.1230 Hall_and_me |
ユーザー |
|
提出日時 | 2020-09-18 21:44:53 |
言語 | C++17 (gcc 13.3.0 + boost 1.87.0) |
結果 |
AC
|
実行時間 | 14 ms / 2,000 ms |
コード長 | 841 bytes |
コンパイル時間 | 700 ms |
コンパイル使用メモリ | 90,652 KB |
最終ジャッジ日時 | 2025-01-14 16:47:54 |
ジャッジサーバーID (参考情報) |
judge3 / judge2 |
(要ログイン)
ファイルパターン | 結果 |
---|---|
sample | AC * 2 |
other | AC * 36 |
ソースコード
// __ // / <@フ // |(ノノハ)) // ノ从゚ヮ゚从 // ノ|ソノГ|つ author:hotarunx // 〈_ノ^^^ヽ| // ~~tァtァ~ #include <algorithm> #include <array> #include <iomanip> #include <iostream> #include <map> #include <numeric> #include <queue> #include <set> #include <stack> #include <vector> using namespace std; #define int long long signed main() { cin.tie(0); ios::sync_with_stdio(0); cout << fixed << setprecision(16); int p, q, r; cin >> p >> q >> r; const int pqr = p + q + r; double ans = 0; ans = max((double)p / pqr, ans); ans = max((double)(q + r) / pqr, ans); ans = max((double)q / pqr, ans); ans = max((double)(p + r) / pqr, ans); ans = max((double)r / pqr, ans); ans = max((double)(p + q) / pqr, ans); cout << ans << "\n"; }