#T733. 倒数累加
倒数累加
Description
Read in , compute the value of $S=1-\frac{1}{2}+\frac{1}{3}-\frac{1}{4}+\frac{1}{5}-\frac{1}{6}+\dots+\frac{1}{n}$. Output the result left-aligned, retaining 10 decimal places.
Input Format
Input a number .
Output Format
Output .
6
0.6166666667
Hint
Data Range:
1 ≤ ≤ 100
Source
CodesOnline