#dpi. [dp_i]Coins
[dp_i]Coins
Problem Statement
Let be a positive odd number.
There are coins, numbered . For each (), when Coin is tossed, it comes up heads with probability and tails with probability .
Taro has tossed all the coins. Find the probability of having more heads than tails.
Constraints
- is an odd number.
- is a real number and has two decimal places.
Input
Input is given from Standard Input in the following format:
Output
Print the probability of having more heads than tails. The output is considered correct when the absolute error is not greater than .
Sample Input 1
Sample Output 1
The probability of each case where we have more heads than tails is as follows:
- The probability of having is ;
- The probability of having is ;
- The probability of having is ;
- The probability of having is .
Thus, the probability of having more heads than tails is .
Sample Input 2
Sample Output 2
Outputs such as 0.500
, 0.500000001
and 0.499999999
are also considered correct.