ysh

杨书蘅  •  6个月前


include <bits/stdc++.h>

using namespace std;

int main() {

double k,  n = 1, s = 0;
scanf("%lf", &k);
while (s <= k) {
	s = s + (1.0 / n) ;
	n++;
}
printf("%.0lf", n - 1);
return 0;

}


评论:

请先登录,才能进行评论