n = gets.to_i
dp = [0.0]*3001
dp[1500] = 1.0
a = gets.split.map(&:to_f)
n.times do |i|
  pr = a[i]
  old = dp.dup
	dp[0] = old[0] + old[1]*(1-pr)
	dp[3000] = old[3000] + old[2999]*pr
	1.upto(2999) do |j|
		dp[j] = old[j-1]*pr + old[j+1]*(1-pr)
	end
end
p dp[1501..3000].reduce(:+)