Note the low memory limit.
After a night at the pub, John needs to walk home. Luckily, the route is very simple: He can walk in a straight line from the pub door until he bumps into his own door, $$$x$$$ meters away. Miraculously, he can still accurately steer the course despite his intoxicated state; however, he has lost control over the length of his steps. The length of each step is uniformly distributed between $$$0$$$ and $$$1$$$ meter, and the lengths of different steps are independent.
Compute the expected number of steps John needs to take until he bumps into his door. He bumps into his door in a step if the length of the step is strictly larger than the remaining distance. The number of steps includes this final step.
Each test contains multiple test cases. The first line contains the number of test cases $$$t$$$ ($$$1 \leq t \leq 10^5$$$). The description of the test cases follows.
Each test case consists of one real number $$$x$$$ ($$$0 \leq x \leq 10^{18}$$$), given with exactly $$$12$$$ digits after the decimal point.
For each test case, output one floating-point number, the expected number of steps.
Your answer is considered correct if its absolute or relative error does not exceed $$$10^{-9}$$$.
Formally, let your answer be $$$a$$$, and the jury's answer be $$$b$$$. Your answer is accepted if and only if $$$\frac{|a - b|}{\max{(1, |b|)}} \le 10^{-9}$$$.
50.0000000000000.5000000000001.0000000000001.5238910597312.000000000000
1.0000000000001.6487212707002.7182818284593.7054159276554.670774270472
| Name |
|---|


