#include <bits/stdc++.h>
using namespace std;
int main() {
  int n, x, ck = 0;
  cin >> n >> x;
  long long int ans1 = 1, ans2 = 1;
  double kk = 1.0;
  double r[2 * n + 5];
  for (int i = 1; i <= 2 * n; i++) {
    cin >> r[i];
    if (r[i] == 1) ck = 1;
  }
  if (ck == 1)
    cout << -1 << endl;
  else {
    for (int i = 1; i <= 2 * n; i++) {
      kk *= ((r[i] - 1) / r[i]);
    }
    double ans;
    ans = (double)(1 - kk) * x;
    ans /= kk;
    printf("%.10lf", ans);
  }
  return 0;
}
