You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

17 lines
276 B

#include <bits/stdc++.h>
using namespace std;
double k;
double x;
int main() {
cin >> k;
for (int cnt = 1;; cnt++) {
x += 2.0 * pow(0.98, cnt - 1);
if (x >= k) {
cout << cnt << endl;
exit(0);
}
}
}