{"raw_statement":[{"iden":"problem statement","content":"Let $N$ be a positive odd number.\nThere are $N$ coins, numbered $1, 2, \\ldots, N$. For each $i$ ($1 \\leq i \\leq N$), when Coin $i$ is tossed, it comes up heads with probability $p_i$ and tails with probability $1 - p_i$.\nTaro has tossed all the $N$ coins. Find the probability of having more heads than tails."},{"iden":"constraints","content":"*   $N$ is an odd number.\n*   $1 \\leq N \\leq 2999$\n*   $p_i$ is a real number and has two decimal places.\n*   $0 < p_i < 1$"},{"iden":"input","content":"Input is given from Standard Input in the following format:\n\n$N$\n$p_1$ $p_2$ $\\ldots$ $p_N$"},{"iden":"sample input 1","content":"3\n0.30 0.60 0.80"},{"iden":"sample output 1","content":"0.612\n\nThe probability of each case where we have more heads than tails is as follows:\n\n*   The probability of having $(Coin 1, Coin 2, Coin 3) = (Head, Head, Head)$ is $0.3 × 0.6 × 0.8 = 0.144$;\n*   The probability of having $(Coin 1, Coin 2, Coin 3) = (Tail, Head, Head)$ is $0.7 × 0.6 × 0.8 = 0.336$;\n*   The probability of having $(Coin 1, Coin 2, Coin 3) = (Head, Tail, Head)$ is $0.3 × 0.4 × 0.8 = 0.096$;\n*   The probability of having $(Coin 1, Coin 2, Coin 3) = (Head, Head, Tail)$ is $0.3 × 0.6 × 0.2 = 0.036$.\n\nThus, the probability of having more heads than tails is $0.144 + 0.336 + 0.096 + 0.036 = 0.612$."},{"iden":"sample input 2","content":"1\n0.50"},{"iden":"sample output 2","content":"0.5\n\nOutputs such as `0.500`, `0.500000001` and `0.499999999` are also considered correct."},{"iden":"sample input 3","content":"5\n0.42 0.01 0.42 0.99 0.42"},{"iden":"sample output 3","content":"0.3821815872"}],"translated_statement":null,"sample_group":[],"show_order":["default"],"formal_statement":null,"simple_statement":null,"has_page_source":true}