A. 级数求和

    Type: Default 1000ms 256MiB

级数求和

You cannot submit for this problem because the contest is ended. You can click "Open in Problem Set" to view this problem in normal mode.

题目描述

已知:Sn=1+12+13++1nS_n= 1+\dfrac{1}{2}+\dfrac{1}{3}+…+\dfrac{1}{n}。显然对于任意一个整数 kk,当 nn 足够大的时候,Sn>kS_n>k

现给出一个整数 kk,要求计算出一个最小的 nn,使得 Sn>kS_n>k

输入格式

一个正整数 kk

输出格式

一个正整数 nn

样例 #1

样例输入 #1

1

样例输出 #1

2

提示

【数据范围】

对于 100%100\% 的数据,1k151\le k \le 15

循环结构小测(四)

Not Attended
Status
Done
Rule
IOI
Problem
5
Start at
2025-7-8 9:00
End at
2025-8-7 9:00
Duration
1.5 hour(s)
Host
Partic.
25