Descriptionosu is a popular leisure software. We can simplify and adapt the rules of OSU to the following: A total of n operations, each operation only success and failure of the points, the success of the corresponding 1, the failure corresponds to the 0,n operation corresponds to 1 length of 01 strings of N. In this string continuous x 1 can contribute to the score of x^3, this x 1 cannot be included in the other continuous 1 (that is, a very long string of 1, see the sample explanation) now give N, as well as the success rate of each operation, please output the desired score, the output is rounded and retained 1 decimal places.
The first line of input has a positive integer n, which indicates the number of operations. Next n rows each row has a real number between [0,1], indicating the success rate of each operation.
Output has only one real number, which indicates the answer. The answer is rounded and retains 1 decimal places.
Sample Input3
0.5
0.5
0.5 Sample Output6.0
HINT
"Sample description"
000 score of 0,001 score for 1,010 score for 1,100 score for 1,101 score for 2,110 score for 8,011 score for 8,111 score for 27, sum of 48, expected for 48/8=6.0
n<=100000
bzoj-4318:osu!