406181: GYM102302 F Drawing cards
Description
You have a box with N cards numbered 1...N and you can also create new cards.
You are going to draw cards from the box, every time you draw a card of a number that has already been drawn you put that card back into the box. If you draw a card of a number that has not been drawn before, you lay it on the desk and you create another card to put back into the box. The number of the new card is chosen randomly with the same probability from the interval [1, N].
In this problem you have to answer what is the expected number of cards on the desk when you draw a card numbered 1 for the first time.
InputOne integer N (1 ≤ N ≤ 106).
OutputOne floating point number, the expected number of cards on the desk when a card with the number 1 is drawn for the first time. Your answer will be considered correct if the absolute and relative error compared with the judge's solution is less than 10 - 4.
ExampleInput2Output
1.5000000000