結果
| 問題 | 
                            No.1230 Hall_and_me
                             | 
                    
| コンテスト | |
| ユーザー | 
                             | 
                    
| 提出日時 | 2020-09-18 21:33:56 | 
| 言語 | C++14  (gcc 13.3.0 + boost 1.87.0)  | 
                    
| 結果 | 
                             
                                WA
                                 
                             
                            
                         | 
                    
| 実行時間 | - | 
| コード長 | 865 bytes | 
| コンパイル時間 | 2,064 ms | 
| コンパイル使用メモリ | 171,220 KB | 
| 実行使用メモリ | 6,948 KB | 
| 最終ジャッジ日時 | 2024-06-22 09:04:54 | 
| 合計ジャッジ時間 | 3,020 ms | 
| 
                            ジャッジサーバーID (参考情報)  | 
                        judge2 / judge1 | 
(要ログイン)
| ファイルパターン | 結果 | 
|---|---|
| sample | AC * 2 | 
| other | AC * 3 WA * 33 | 
ソースコード
#include <bits/stdc++.h>
//#include <atcoder/all>
typedef unsigned long long ULLONG;
typedef long long LLONG;
static const LLONG MOD_NUM = 1000000007; //998244353;
template<class _T> static void get(_T& a) {
	std::cin >> a;
}
template<class _T> static void get(_T& a, _T& b) {
	std::cin >> a >> b;
}
template<class _T> static void get(_T& a, _T& b, _T& c) {
	std::cin >> a >> b >> c;
}
template <class _T> static _T tp_abs(_T a) {
	if (a < (_T)0) {
		a *= (_T)-1;
	}
	return a;
}
static void A();
int main()
{
	A();
	fflush(stdout);
	return 0;
}
static void A()
{
	double P, Q, R;
	get(P, Q, R);
	double ttl = P + Q + R;
	std::vector<double> p(3);
	p[0] = P / ttl;
	p[1] = Q / ttl;
	p[2] = R / ttl;
	std::sort(p.begin(), p.end(), std::greater<double>());
	double ans = p[0];
	if (p[0] < (p[1] + p[2])) {
		ans = p[1] + p[2];
	}
	printf("%.10lf\n", ans);
}