Just Print Sample
该比赛已结束,您无法在比赛模式下递交该题目。您可以点击“在题库中打开”以普通模式查看和递交本题。
Description
Libra is participating in AHUPC. She meets an extremely hard problem which is required to print a single yes
or no
. This problem has distinct test cases weighted equally. Her final score will equal the number of test cases that her last submission passes.
Libra has no idea for this problem, thus she will try to print yes
or no
each with probability , independently for each test case.
Libra knows that she cannot submit more than times in total because then she will certainly be disqualified. What is the maximum possible expected value of Libra's final score, assuming that she follows the optimal strategy?
Format
Input
The only line of input contains two space-separated integers and ().
Output
The answer as a decimal that differs by at most absolute or relative error from the actual answer.
Samples
1 3
0.8750000000
3 2
1.8750000000
24 97
17.5176275613