Problem:


Score : 200 points

Problem Statement

Takahashi has a deposit of 100 yen (the currency of Japan) in AtCoder Bank.

The bank pays an annual interest rate of 1 % compounded annually. (A fraction of less than one yen is discarded.)

Assuming that nothing other than the interest affects Takahashi's balance, in how many years does the balance reach X yen or above for the first time?

Constraints

 101 \le X \le 10^{18} 

All values in input are integers.

Input

Input is given from Standard Input in the following format:

X

Output

Print the number of years it takes for Takahashi's balance to reach X yen or above for the first time.

Sample Input 1

103

Sample Output 1

3

The balance after one year is 101 yen.

The balance after two years is 102 yen.

The balance after three years is 103 yen.

Thus, it takes three years for the balance to reach 103 yen or above.

Sample Input 2

1000000000000000000

Sample Output 2

3760

Sample Input 3

1333333333

Sample Output 3

1706



Sample input:
103


Sample output:
3

Submission status: Runtime Error

Solution code:
#include<bits/stdc++.h>
#include<iostream>
#include<string>
#include<set>
using namespace std;
#define rep(i, a, n) for (int i = a; i < n; i++)
typedef long long ll;

signed main(){
    //B
    /*
    int k,a,b;
    cin>>k>>a>>b;
    for(int i=a;i<=b;i++){
        if(i%k==0){
            cout<<"OK"<<endl;
            return 0;
        }
    }
    cout<<"NG"<<endl;
    return 0;
    */
   //B
   ll x;
   cin>>x;
   ll p=100;
   int c=0;
   while(p<x){
       p=ll(p+p*0.01);
       c++;
   }
   cout<<c<<endl;
}

Submission status: Runtime Error

Solution code:
m = 100
quota = int(input())
cnt = 0
while(m<=quote):
  m = int(m*1.01)
  cnt += 1
  
print(cnt)

Submission status: Runtime Error

Solution code:
import math
X=int(input())
u=100
y=0
while u>=0:
  u=math.floor(u*1.01)
  y+=1
print(y)

Submission status: Runtime Error

Solution code:
a = int(input())
A = []
for i in range(101, a+1):
    i.append(A)
print(len(A))

Submission status: Runtime Error

Solution code:
x = int(input())
import sys
sys.setrecursionlimit(2000)

def f(n):
  if n == 1:
    return 101
  else:
    return int(f(n-1)*1.01)
n = 1
while f(n) < x:
  n += 1
else:
  print(n)

Submission status: Runtime Error

Solution code:
N=int(input())

x=100.0
for i in range(N):
    x=math.floor(x*1.01)
    if(x>=N):
        print(i+1)
        break;
    i+=1

Submission status: Runtime Error

Solution code:
X = int(input())
base = 100
rt = 0
while X > base:
    base = math.floor(base * 1.01)
    rt += 1
print(rt)

Submission status: Runtime Error

Solution code:
a = int(input())
A = []
for i in range(101, a):
    i.append(A)
print(len(A))

Submission status: Runtime Error

Solution code:
k=100
for i in range(10000):
    if k >= x:
        print(i)
        break
    k= k*1.01 // 1

Submission status: Runtime Error

Solution code:
n=int(input())
money=100
year=0
while(money<n){
  year=year+1
  money=money*1.01
}
print(year)

Submission status: Runtime Error

Solution code:
X=int(input())
u=100
y=0
while u>=0:
  u=int(u*1.01)
  y+=1
print(y)

Submission status: Runtime Error

Solution code:
import sys
K=int(input())
 
A,B=list(map(int, input().split()))
 
for i in range(A,B+1):
  if i%K==0:
    
    print("Yes")
    sys.exit()

print("No")

Submission status: Runtime Error

Solution code:
import math
X = int(input())
money = 100
y = 1
while X > money:
  money += moth.floor(money*0.01)
  y += 1
  
print(y)

Submission status: Runtime Error

Solution code:
x = int(input())
n = 100
for i in range(123123):
	if(n >= x):
		print(i)
		return
	now = (now * 101) // 100

Submission status: Runtime Error

Solution code:
import math

X = int(input())

cur = 100
i = 0

while cur < X:
  cur = math.fllor(cur * 1.01)
  i += 1
  
print(i)

Submission status: Runtime Error

Solution code:
X = int(input())
a = log(X/100, 1.01)
print(int(a)+1)

Submission status: Runtime Error

Solution code:
x=(int)(input())
y=100
count=0
while x>y:
  y=(101*y)//100
  count=count+1
cout<<count

Submission status: Runtime Error

Solution code:
x = int(input())
l = [1]

total = 100
rate = 1

year = 0

while total < x :
    total = total + total // 100
   year += 1

print(year)

Submission status: Runtime Error

Solution code:
X = int(input())
check = false
ans = 100
count = 0
while ans < X:
  ans *= 1.01
  count += 1
print(count)

Submission status: Runtime Error

Solution code:
x=int(input)
m=100
cnt=0
while x>m:
    cnt+=1
    m=(m*1.01)//1
print(str(cnt))

Submission status: Runtime Error

Solution code:
x = int(input())

n = 100

i = 0

while n < x:
    n = math.floor(n * 1.01)
    i += 1

print(i)

Submission status: Runtime Error

Solution code:
t=input()
import math
print (math.log(t)-math.log(100))/math.log(1.01)

Submission status: Runtime Error

Solution code:
x=int(input())
y=100
for i in range(10**9):
  y=y*1.01**i
  if y>=x:
    print(i)

Submission status: Runtime Error

Solution code:
#!/usr/bin/env python
# -*- coding: utf-8 -*-

import pysnooper # @pysnooper.snoop()
from pprint import pprint as pp
from pprint import pformat as pf

import math


if __name__ == '__main__':
    x = int(input())
    money = 100
    count = 0
    while not (money >= x):
        money = math.floor(money * 101 / 100)
        count += 1
    print(count)

Submission status: Runtime Error

Solution code:
x = int(input())
n = 100

for i in range(1e5):
  n = (n * 101) // 100
  if n >= x:
	print(i + 1)
    break

Submission status: Runtime Error

Solution code:
X = int(input())

tmp = 100
cnt = 
while tmp < X:
    tmp = tmp + int(tmp*0.01)
    cnt += 1

print(cnt)

Submission status: Runtime Error

Solution code:
import math
X=int(input())
a=0
o=100
while True:
  o*=1.01
  o=math.floor()
  a+=1
  if o>=X:
    print(a)
    break

Submission status: Runtime Error

Solution code:
num = input()
a = 100
count = 0
while count>=0:
  a = a * 1.1
  count = count + 1
  if a>=num:
    break
print(count)

Submission status: Runtime Error

Solution code:
x=input()
tmp=100
for i in range(10000):
  if tmp>=x:
    print(i)
    break
  tmp+=tmp//100

Submission status: Runtime Error

Solution code:
a =int(input())
cur = 100
n = 0
while cur<a-1e-5:
  cur = cur*1.01
  cnt+=1
print(cnt)