import std.conv;
import std.string;
import std.algorithm;
import std.array;
import std.stdio;

void main() {
	readln;
	double[] ps = readln.chomp.split(' ').map!(to!double).array;
	double[][] dp = new double[][ps.length + 1];
	foreach (ref e;dp) {
		e = new double[ps.length + 1];
		e[0] = 1.0;
	}
	dp[0][1..$] = 0.0;

	foreach (i;0..ps.length) {
		dp[i + 1][0] = dp[i][0] * (1 - ps[i]);
		foreach (o;1..ps.length + 1) {
			dp[i + 1][o] = dp[i][o - 1] * ps[i] + dp[i][o] * (1 - ps[i]);
		}
	}

	auto result = dp[ps.length][ps.length / 2 + 1..$].sum;
	writefln("%.10f", result);
}
