Problem2080--分数和

2080: 分数和

Time Limit: 1 Sec  Memory Limit: 128 MB
Submit: 68  Solved: 53
[Status] [Submit] [Creator:]

Description

本题中,我们用 a/b 表示分数 “b分之a”。

现在给你一个整数 n,求 1/2 + 1/3 + 1/4 + …… 1/n ,结果保留 3 位小数。

Input

一个整数 n(2 ≤ n ≤ 100)。

Output

输出 1/2 + 1/3 + 1/4 + …… 1/n 保留 3 位小数的结果。

Sample Input Copy

3

Sample Output Copy

0.833

Source/Category