#include using namespace std; using ll = long long; int main() { cin.tie(0); ios::sync_with_stdio(false); int n; cin >> n; long double p, q; cin >> p >> q; q += p; int seed = 0; mt19937 mt(seed); uniform_real_distribution rnd(0, 1); int cnt = 0; const int LOOP_NUM = 2000000; for (int i = 0; i < LOOP_NUM; i++) { int cur = 1; int d = 1; while (true) { long double val = rnd(mt); if (val <= p) { d = -d; cur += d; } else if (val <= q) { cur += d; } else { break; } if (cur == n + 1) break; if (cur == 0) { cnt++; break; } } } cout << fixed << setprecision(15) << (double)cnt / LOOP_NUM << endl; return 0; }