local n=io.read("n")
local p={}
for i=1,n do
    p[i]=io.read("n")
end

local dp={}
for i=1,n+1 do
    dp[i]={}
    for j=0,i do
        dp[i][j]=0
    end
end
dp[1][0]=1

for i=1,n do
    for j=0,i do
        dp[i+1][j+1]=dp[i+1][j+1]+dp[i][j]*p[i]
        dp[i+1][j]=dp[i+1][j]+dp[i][j]*(1-p[i])
    end
end

local total=0
for i=n//2+1,n do
    total=total+dp[n+1][i]
end
print(total)