#include <bits/stdc++.h>
using namespace std;
const int N = 100000;
const long double eps = 1e-16;
vector<long double> solve(int hp, int l, int r, int p) {
  vector<long double> ans(N);
  vector<vector<long double> > dp(N, vector<long double>(hp + 1));
  long double prob = (100.0 - p) / (100.0) / (r - l + 1.0),
              fail_prob = p / 100.0;
  dp[0][hp] = 1.0;
  for (int i = 0; i < N - 1; ++i) {
    ans[i] = dp[i][0];
    for (int j = 1; j <= hp; ++j) {
      if (dp[i][j] < eps) continue;
      for (int k = l; k <= r; ++k) {
        dp[i + 1][max(j - k, 0)] += prob * dp[i][j];
      }
      dp[i + 1][j] += dp[i][j] * fail_prob;
    }
  }
  return ans;
}
int hp[2], dt[2], l[2], r[2], p[2];
vector<long double> pkill[2];
int main() {
  for (int i = 0; i < 2; ++i) cin >> hp[i] >> dt[i] >> l[i] >> r[i] >> p[i];
  if (p[0] == 100 && p[1] == 100) {
    cout << "0.0\n";
    return 0;
  }
  if (p[0] == 100) {
    cout << "0.0\n";
    return 0;
  }
  if (p[1] == 100) {
    cout << "1.0\n";
    return 0;
  }
  for (int i = 0; i < 2; ++i) pkill[i] = solve(hp[i ^ 1], l[i], r[i], p[i]);
  long double ans = 0.0;
  for (int i = 1; i < N; ++i) pkill[1][i] += pkill[1][i - 1];
  for (int shots = 1; shots < N; ++shots) {
    int op_shots = ((shots - 1) * dt[0] - 1) / dt[1] + (shots > 1);
    op_shots = min(op_shots, N - 1);
    ans += pkill[0][shots] * ((long double)1.0 - pkill[1][op_shots]);
  }
  cout << fixed << setprecision(16);
  cout << ans << '\n';
}
