#include "bits/stdc++.h"

using namespace std;

using i64 = long long;

const i64 MOD = 1e9+7;

const i64 INF = 1e18+7;


template <typename T = i64>
bool chmax(T& a, T b){
    if(a < b){
        a = b;
        return true;
    }
    return false;
}

template <typename T = i64>
bool chmin(T& a, T b){
    if(a > b){
        a = b;
        return true;
    }
    return false;
}


signed main(){

    cin.tie(0);
    ios::sync_with_stdio(false);
    cout << fixed << setprecision(20);

    int a, b, p, q, r;
    cin >> a >> b >> p >> q >> r;

    auto f = [&](double val){
        double e8 = 0;
        e8 += p * b;
        e8 -= (val - b) * r;
        double sq = (val - a) * q;
        return e8 >= sq;
    };

    double ok = b;
    double ng = 1e9;
    for(int i = 0; i < 100; ++i){
        double mid = (ok + ng) / 2;
        (f(mid) ? ok : ng) = mid;
    }
    cout << ok << endl;
}

