Because of necessary software maintenance, Jutge.org may not work well on the afternoons of the 20th and 21th of april.
Harmonic numbers (1)
P59539
Statement
html
Write a program that reads a number n
and prints the n-th harmonic number,
defined as Hn = 1/1 + 1/2 + ⋯ + 1/n.
Input
Input consists of a natural number n.
Output
Print Hn with 4 digits after the decimal point.
About statements
The official statement of a problem is always the one
in the PDF document. The HTML version of the statement
is also given to help you, but may contain some content
that is not well displayed. In case of doubt, always use the PDF.