#include <bits/stdc++.h>
using namespace std;
int main(){
  int N;
  cin >> N;
  vector<double> head(N+1);
  double p;
  cin >> p;
  head[0] = 1-p;
  head[1] = p;
  for(int i = 1; i < N; ++i){
    cin >> p;
    for(int j = i+1; j >= 0; --j){
      head[j] *= (1-p);
      if(j > 0) head[j] += head[j-1]*p;
    }
  }
  double ret = 0;
  for(int i = (N+1)/2; i <= N; ++i) ret += head[i];
  cout << fixed << setprecision(10) << ret;
  return 0;
}