結果

問題 No.236 鴛鴦茶
ユーザー よっか
提出日時 2015-07-05 22:33:57
言語 C++11(廃止可能性あり)
(gcc 13.3.0)
結果
WA  
実行時間 -
コード長 653 bytes
コンパイル時間 711 ms
コンパイル使用メモリ 84,984 KB
実行使用メモリ 6,948 KB
最終ジャッジ日時 2024-07-07 23:14:16
合計ジャッジ時間 1,290 ms
ジャッジサーバーID
(参考情報)
judge1 / judge3
このコードへのチャレンジ
(要ログイン)
ファイルパターン 結果
sample AC * 2
other AC * 18 WA * 5
権限があれば一括ダウンロードができます

ソースコード

diff #

#include <iostream>
#include <vector>
#include <deque>
#include <stack>
#include <memory>
#include <functional>
#include <algorithm>
#include <map>
#include <list>
#include <complex>
#include <string>
#include <cstdio>
#include <cstring>
#include <cstdlib>
#include <cmath>
#include <numeric>
#include <array>
using namespace std;
typedef std::pair<int, int> pii;
typedef long long int ll;

#define pb push_back

const long long int MOD = 1e9+7;

int main(){
		
	int A, B, X, Y;

	cin >> A >> B >> X >> Y;

	double a = X * (double)B/A;
	double b = Y * (double)A/B;

	if(b <= X) printf("%.8f\n", b + Y);
	if(a <= Y) printf("%.8f\n", a + X);

	return 0;
}
0