Problem:


Score : 300 points

Problem Statement

As a token of his gratitude, Takahashi has decided to give his mother an integer sequence.
The sequence A needs to satisfy the conditions below:

A consists of integers between X and Y (inclusive).

For each 1\leq i \leq |A|-1, A_{i+1} is a multiple of A_i and strictly greater than A_i.

Find the maximum possible length of the sequence.

Constraints

1 \leq X \leq Y \leq 10^{18}

All input values are integers.

Input

Input is given from Standard Input in the following format:

X Y

Output

Print the maximum possible length of the sequence.

Sample Input 1

3 20

Sample Output 1

3

The sequence 3,6,18 satisfies the conditions.

Sample Input 2

25 100

Sample Output 2

3

Sample Input 3

314159265 358979323846264338

Sample Output 3

31



Sample input:
3 20


Sample output:
3

Submission status: Wrong Answer

Solution code:
X,Y = map(int, input().split())
C = Y/X
i = 0
ans = 0
while (2**(i)<=C):
    ans += 1
    i += 1
print(ans)

Submission status: Wrong Answer

Solution code:
X, Y =map(int,input().split())
division=(Y-Y%X)/X
data=1
count=1
while division>data:
    data=data*2
    count+=1
    
if division==data:
    print (count)
else:
    print(count-1)

Submission status: Wrong Answer

Solution code:
X, Y =map(int,input().split())
division=(Y-Y%X)/X
data=2
count=0
while division>data:
    data=data*2
    count+=1
print(count+1)

Submission status: Wrong Answer

Solution code:
X, Y =map(int,input().split())
division=(Y-Y%X)/X
data=2
count=0
while division>=data:
    data=data*2
    count+=1
print(count+1)

Submission status: Wrong Answer

Solution code:
x, y = (int(i) for i in input().split())
tmpx = x
count = 0
while tmpx<=y:
    tmpx = tmpx * 2^count
    count = count + 1

print(count)

Submission status: Wrong Answer

Solution code:
x, y = [int(x) for x in input().split()]
size = int(y/x).bit_length()
print(size)

Submission status: Wrong Answer

Solution code:
import math
x, y = [int(x) for x in input().split()]
size = int(math.log2(float(y/x))) + 1
print(size)

Submission status: Wrong Answer

Solution code:
import math
x, y = [float(x) for x in input().split()]
size = int(math.log2(y/x)) + 1
print(size)

Submission status: Wrong Answer

Solution code:
import math
x, y = [int(x) for x in input().split()]
size = int(math.log2(y//x)) + 1
print(size)

Submission status: Wrong Answer

Solution code:
import math
x, y = [int(x) for x in input().split()]
size = int(math.log2(y/x)) + 1
if x == y:
  print(0)
else:
  print(size)

Submission status: Wrong Answer

Solution code:
import math
x, y = [int(x) for x in input().split()]
size = math.log2(y/x) + 1
if x == y:
  print(0)
else:
  print(size)

Submission status: Wrong Answer

Solution code:
x, y = [int(x) for x in input().split()]
size = int.bit_length(y//x)
if x == y:
  print(0)
else:
  print(size)

Submission status: Wrong Answer

Solution code:
x, y = [int(x) for x in input().split()]
size = int.bit_length(y//x)
if size == 1:
  print(0)
else:
  print(size)

Submission status: Wrong Answer

Solution code:
x, y = [float(x) for x in input().split()]
size = int.bit_length(int(y/x))
print(size)

Submission status: Wrong Answer

Solution code:
import math
x, y = [int(x) for x in input().split()]
size = int(math.log2(y/x)) + 1
print(size)

Submission status: Wrong Answer

Solution code:
x, y = map(int, input().split())
n=0
while(2**n<=y/x):
    n+=1
print(n)

Submission status: Wrong Answer

Solution code:
import math
x, y = map(int,input().split())
print(int(math.log2(y/x))+1)

Submission status: Wrong Answer

Solution code:
import math
x, y = map(int,input().split())
if y/x <= 1:
  print(1)
else:
  print(int(math.log(y//x,2))+1)

Submission status: Wrong Answer

Solution code:
import math
x, y = map(int,input().split())
print(int(math.log(y/x,2)) + 1)

Submission status: Wrong Answer

Solution code:
import math
x, y = map(int,input().split())
print(math.log(y/x,2)//1 + 1)

Submission status: Wrong Answer

Solution code:
import math
x, y = map(int,input().split())
print(int(math.log(y/x,2))+1)

Submission status: Wrong Answer

Solution code:
from math import log
n = list(map(int,input().split()))
x, y = n[0],n[1]
t = y/x
for i in range(0,100):
  if 2 ** i > t:
    print(i)
    quit()

Submission status: Wrong Answer

Solution code:
from math import log
n = list(map(int,input().split()))
x, y = n[0],n[1]
if x == y:
 print(1)
else:
 print(int(log(y//x,2)+1))

Submission status: Wrong Answer

Solution code:
from math import log
n = list(map(int,input().split()))
x, y = n[0],n[1]
if x == y:
 print(1)
else:
 print(int(log(y/x,2)+1))

Submission status: Wrong Answer

Solution code:
from math import log
n = list(map(int,input().split()))
x, y = n[0],n[1]
print(int(log(y/x,2)+1))

Submission status: Wrong Answer

Solution code:
from math import log
n = list(map(int,input().split()))
x, y = n[0],n[1]
print(int(log(y/x,2)))

Submission status: Wrong Answer

Solution code:
from math import log, floor

def formula(x, y):
    return 1 + floor(log(y / x, 2))

if __name__ == '__main__':
    x, y = map(int, input().split())
    print(formula(x, y))

Submission status: Wrong Answer

Solution code:
from math import log, floor

x, y = map(int, input().split())
print(1 + floor(log(y / x, 2)))

Submission status: Wrong Answer

Solution code:
X,Y = map(int,input().split())
counter = 0
A = X
A_sum = 0
while A_sum <= Y:
    A_sum += A
    A *= 2
    counter += 1
print(counter)

Submission status: Wrong Answer

Solution code:
import bisect


def calc(X, Y):
    dic = dict([(X * (2**x), x) for x in range(80)])
    ret = bisect.bisect(list(dic.keys()), Y)

    return ret


def calc2(X, Y):
    cnt = 0
    tmp = X
    while tmp <= Y:
        tmp *= 2
        cnt += 1
    return cnt


def main():
    X, Y = list(map(int, input().split()))
    print(calc(X, Y))
    # print(calc2(X, Y))


if __name__ == '__main__':
    main()
    # import random
    # for i in range(3000000):
    #     x = random.randint(1, 1000000000000000000)
    #     y = random.randint(x, 1000000000000000000)
    #     if (calc(x, y) != calc2(x, y)):
    #         print(x, y)

Submission status: Wrong Answer

Solution code:
import bisect

X, Y = list(map(int, input().split()))

dic = dict([(X * (2**x), x) for x in range(80)])

ret = bisect.bisect(list(dic.keys()), Y)
# print(ret)

# print(list(dic.keys())[:ret])
print(len(list(dic.keys())[:ret]))

Submission status: Wrong Answer

Solution code:
import bisect

X, Y = list(map(int, input().split()))

dic = dict([(X * (2**x), x) for x in range(80)])

print(bisect.bisect(list(dic.keys()), Y))

Submission status: Wrong Answer

Solution code:
import bisect
X, Y = list(map(int, input().split()))
dic = dict([(X * (2**x), x) for x in range(60)])
print(bisect.bisect(list(dic.keys()), Y))

Submission status: Wrong Answer

Solution code:
# -*- coding: utf-8 -*-

# AtCoder Beginner Contest
# Problem C

if __name__ == '__main__':
    x, y = map(int, input().split())

    from math import log2

    if x == 1 and y == 1:
        result = 0
    else:
        result = int(log2(y / x)) + 1
    print(result)

Submission status: Wrong Answer

Solution code:
# -*- coding: utf-8 -*-

# AtCoder Beginner Contest
# Problem C

if __name__ == '__main__':
    x, y = map(int, input().split())

    from math import log2
    result = int(log2(y / x)) + 1
    print(result)

Submission status: Wrong Answer

Solution code:
X,Y=map(int,input().split())
t=X
i=0
for i in range(1,X*Y):
    if t*2>Y: break
    else:
        t*=2

print(i)

Submission status: Wrong Answer

Solution code:
X, Y = [int(item) for item in input().rstrip().split(" ")]
 
ans = 0
while(1):
  if X < Y:
    ans+=1
    X *=2
  else:
    break
print(ans)

Submission status: Wrong Answer

Solution code:
X, Y = [int(item) for item in input().rstrip().split(" ")]
 
ans = 1
while(1):
  if X < Y:
    ans+=1
    X *=2
  else:
    break
print(ans)

Submission status: Wrong Answer

Solution code:
X,Y=map(int,input().split())
dev = int(Y/X)
work = 1
for i in range(74):
  tmp = pow(2,i)
  if tmp <= dev and dev < tmp*2:
    work +=i
    break
print(work)

Submission status: Wrong Answer

Solution code:
X,Y=map(int,input().split())
dev = int(Y/X)
work = 1
for i in range(72):
  tmp = pow(2,i)
  if tmp <= dev and dev < tmp*2:
    work +=i
    break
print(work)

Submission status: Wrong Answer

Solution code:
X,Y=map(int,input().split())
dev = int(Y/X)
work = 1
for i in range(61):
  tmp = pow(2,i)
  if tmp <= dev and dev < tmp*2:
    work +=i
    break
print(work)

Submission status: Wrong Answer

Solution code:
X,Y=map(int,input().split())
dev = int(Y/X)

for i in range(60):
  tmp = pow(2,i)
  if tmp <= dev and dev < tmp*2:
    print(i+1)

Submission status: Wrong Answer

Solution code:
import math

X, Y = list(map(int, input().split()))

A = 1 + math.log10(Y/X)/math.log10(2)

print(int(A))

Submission status: Wrong Answer

Solution code:
import math

X, Y = list(map(int, input().split()))

A = 1 + math.log(Y/X)/math.log(2)

print(int(A))

Submission status: Wrong Answer

Solution code:
import math

X, Y = list(map(int, input().split()))

A = 1 + math.log(Y/X)//math.log(2)

print(int(A))

Submission status: Wrong Answer

Solution code:
import numpy as np
from collections import Counter
import collections
round = lambda x:(x*2+1)//2
a = list(map(float,input().split()))
a = np.array(a)
X = a[0]
Y = a[1]
i = 0
while(X<=Y):
  X *= 2
  i+=1
print(i)

Submission status: Wrong Answer

Solution code:
import numpy as np
from collections import Counter
import collections
round = lambda x:(x*2+1)//2
a = list(map(float,input().split()))
a = np.array(a)
X = a[0]
Y = a[1]
for i in range(100):
  if int(Y) < int(X)*2**i:
    print(i)
    break

Submission status: Wrong Answer

Solution code:
import numpy as np
from collections import Counter
import collections
round = lambda x:(x*2+1)//2
a = list(map(float,input().split()))
a = np.array(a)
X = a[0]
Y = a[1]
for i in range(1000):
  if Y < X*2**i:
    print(i)
    break

Submission status: Wrong Answer

Solution code:
import numpy as np
from collections import Counter
import collections
round = lambda x:(x*2+1)//2
a = list(map(float,input().split()))
a = np.array(a)
X = a[0]
Y = a[1]
for i in range(100):
  if Y < X*2**i:
    print(i)
    break

Submission status: Wrong Answer

Solution code:
import math
x,y=map(int,input().split())
print(int(math.log(y/x,2)+1))
"""
x*2**n<=y
2**n<=y/x
n<=log(y/x,2)
"""

Submission status: Wrong Answer

Solution code:
from math import log
x, y = map(float, raw_input().split())

print int(log(y/x,2))+1

Submission status: Wrong Answer

Solution code:
import math
x,y= map(int,input().split())
ans = int( math.log2(y/x) + 1 )
print(ans)

Submission status: Wrong Answer

Solution code:
import math

X, Y = map(int, input().split())
P = Y // X
N = math.floor(math.log2(P))
print(N+1)

Submission status: Wrong Answer

Solution code:
x, y = (int(i) for i in input().split())
count = 1 
i = x

while i < y:
    if i*2 < y:
        count += 1
        i = i*2
    else:
        break
print(count)

Submission status: Wrong Answer

Solution code:
x, y = map(int, input().split())
 
num = 0
while x < y:
    num += 1
    x *= 2
    
print(num)

Submission status: Wrong Answer

Solution code:
x, y = map(int, input().split())
 
num = 1
while x < y:
    x *= 2
    num += 1
 
print(num)

Submission status: Wrong Answer

Solution code:
from math import log
 
x, y = map(int, input().split())
 
print(int(log(y // x,2)) + 1)

Submission status: Wrong Answer

Solution code:
from math import log

x, y = map(int, input().split())

print(int(log(y,2) - log(x,2)) + 1)

Submission status: Wrong Answer

Solution code:
import math
a, b = map(int, input().split())
print(math.floor(math.log(b/a,2))+1)

Submission status: Wrong Answer

Solution code:
# -*- coding: utf-8 -*-

import sys

x, y = [int(e) for e in raw_input().split()]
#print x, y

m = y / x
i = 1
l = 1
while True:
    if i > m:
        break
    m -= i
    i <<= 1
    l += 1
    
sys.stdout.write('%d\n' % (l))
sys.stdout.flush()

Submission status: Wrong Answer

Solution code:
import math
X, Y = list(map(int, input().split()))
print(math.ceil(math.log(Y/X+1, 2)))

Submission status: Wrong Answer

Solution code:
import math
X, Y = list(map(int, input().split()))
print(math.floor(math.log(Y/X, 2))+1)

Submission status: Wrong Answer

Solution code:
import math

X, Y = map(int, input().split())
print(int(math.log(Y / X, 2)) + 1)

Submission status: Wrong Answer

Solution code:
import math
x,y = map(int,input().split())
i = int(math.log2(y//x) // 1) + 1
print(i)

Submission status: Wrong Answer

Solution code:
import math
x,y = map(int,input().split())
i = int(math.log2(y/x) // 1) + 1
print(i)

Submission status: Wrong Answer

Solution code:
import numpy as np
import pdb
import copy

def main():
    [X, Y] = map(float,  raw_input().split(' '))
    print int(longest(X,Y))

def longest(X,Y):
    ratio = Y / X
    maxfill = np.floor(np.log2(ratio))
    #must include 0.
    return maxfill + 1



if __name__ == '__main__':
    main()

Submission status: Wrong Answer

Solution code:
X,Y = map(int, input().split())

for i in range(1,60):
    if X * (2**i) > Y:
        print(i)
        break

Submission status: Wrong Answer

Solution code:
# C - Multiple Gift
import math

X, Y = map(float, raw_input().split())
division = Y / X
result = int(math.floor(math.log(division, 2))) + 1

print result

Submission status: Wrong Answer

Solution code:
import math

X, Y = map(int, input().split())
k = math.floor(math.log(Y/X, 2) + 1)
print(k)

Submission status: Wrong Answer

Solution code:
import math

X, Y = map(int, input().split())
k = math.floor(math.log(Y/X, 2)) + 1
print(k)

Submission status: Wrong Answer

Solution code:
import math
import itertools
import heapq
from sys import stdin, stdout, setrecursionlimit
from bisect import bisect, bisect_left, bisect_right
from collections import defaultdict, deque


# d = defaultdict(lambda: 0)
# setrecursionlimit(10**7)
# inf = float("inf")


##### stdin ####
def LM(t, r): return list(map(t, r))
def R(): return stdin.readline()
def RS(): return R().split()
def I(): return int(R())
def F(): return float(R())
def LI(): return LM(int,RS())
def LF(): return LM(float,RS())
def ONE_SL(): return list(input())
def ONE_IL(): return LM(int, ONE_SL())
def ALL_I(): return map(int, stdin)
def ALL_IL(): return LM(int,stdin)

##### tools #####
def ap(f): return f.append
def pll(li): print('\n'.join(LM(str,li)))
def pljoin(li, s): print(s.join(li))

##### main #####



def main():
	x,y = LI()
	if y%x==0:
		ans=1
	else:
		ans=0

	while x<y:
		
		x*=2
		ans+=1
		
	print(ans)

if __name__ == '__main__':
	main()

Submission status: Wrong Answer

Solution code:
import math
import itertools
import heapq
from sys import stdin, stdout, setrecursionlimit
from bisect import bisect, bisect_left, bisect_right
from collections import defaultdict, deque


# d = defaultdict(lambda: 0)
# setrecursionlimit(10**7)
# inf = float("inf")


##### stdin ####
def LM(t, r): return list(map(t, r))
def R(): return stdin.readline()
def RS(): return R().split()
def I(): return int(R())
def F(): return float(R())
def LI(): return LM(int,RS())
def LF(): return LM(float,RS())
def ONE_SL(): return list(input())
def ONE_IL(): return LM(int, ONE_SL())
def ALL_I(): return map(int, stdin)
def ALL_IL(): return LM(int,stdin)

##### tools #####
def ap(f): return f.append
def pll(li): print('\n'.join(LM(str,li)))
def pljoin(li, s): print(s.join(li))

##### main #####



def main():
	x,y = LI()
	ans=0
	
	while x<y:
		
		x*=2
		ans+=1
		
	print(ans)

if __name__ == '__main__':
	main()

Submission status: Wrong Answer

Solution code:
x,y=map(int,input().split())
i=0
while x<y:
    i+=1
    x=x*2
print(i)

Submission status: Wrong Answer

Solution code:
import math
X, Y = map(int, raw_input().split())

print(int(math.floor(math.log(Y/X, base=2)) + 1))

Submission status: Wrong Answer

Solution code:
X, Y = map(int,input().split())
length = 1
P = X
while(P <= Y):
    P = 2*P
    print(P)
    length += 1

length = length -1
print(length)

Submission status: Wrong Answer

Solution code:
from math import log 

r = lambda : map(int, raw_input().split())

x, y = r()

print ( int(log(y/x, 2)) + 1)

Submission status: Wrong Answer

Solution code:
from math import log
x, y = map(float, raw_input().split())
print int(log(y / x, 2)) + 1

Submission status: Wrong Answer

Solution code:
import math
X, Y = map(int, input().split())

n = int(math.log2(Y/X))
res = 1 + n

print(res)

Submission status: Wrong Answer

Solution code:
import math
X, Y = map(int, input().split())

res = -1
if X == Y:
	res = 0
else:
	n = int(math.log2(Y//X))
	res = 1 + n

print(res)

Submission status: Wrong Answer

Solution code:
import math
X, Y = map(int, input().split())

res = -1
if X == Y:
	res = 0
else:
	n = int(math.log2(Y/X))
	res = 1 + n

print(res)

Submission status: Wrong Answer

Solution code:
x,y = map(int,input().split())
cnt = 0
while(x <= y):
    x = x * pow(2,cnt)
    cnt += 1
print(cnt)

Submission status: Wrong Answer

Solution code:
import math
from decimal import *
X,Y=map(Decimal,input().split())
print(int(math.log2(Y//X))+1)

Submission status: Wrong Answer

Solution code:
def main():
   X,Y = map(int,input().split())
   t = 0
   v = 1
   for i in range(1,Y+1):
      if v*i <= Y:
         t+= 1
      v *= i
   print(t)
main()

Submission status: Wrong Answer

Solution code:
import math
X, Y = map(int, input().split())
print(math.floor(math.log(Y/X, 2))+1)

Submission status: Wrong Answer

Solution code:
X, Y = map(int, input().split())
maxstack = []
stack = []
for i in range(X, Y+1):
    j = i
   # print("j",j)
    while j <= Y+1:
   #     print("loopj",j)
        stack.append(j)
        j *= 2
   #     print(stack, len(stack))
    if len(maxstack) < len(stack):
        maxstack.clear()
        maxstack.extend(stack)
    #print(maxstack)    
    stack.clear()
print(len(maxstack))

Submission status: Wrong Answer

Solution code:
# your code goes here
x,y = map(int,input().split())
i = 0
while (2**i * x) < y:
	i += 1

print(i)

Submission status: Wrong Answer

Solution code:
from pprint import pprint as pp
import collections
import math
x,y = list(map(int, input().split()))

bai = y/x
l = math.log2(bai)
print(int(math.floor(l)+1))

Submission status: Wrong Answer

Solution code:
from pprint import pprint as pp
import collections
import math
x,y = list(map(int, input().split()))

bai = y/x
if bai==int(bai):
  print(int(math.ceil(math.log2(bai))+2))
else:
  print(int(math.floor(math.log2(bai))+1))

Submission status: Wrong Answer

Solution code:
from pprint import pprint as pp
import collections
import math
x,y = list(map(int, input().split()))

bai = y/x
if bai==int(bai):
  print(int(math.ceil(math.log2(bai))+1))
else:
  print(int(math.floor(math.log2(bai))+1))

Submission status: Wrong Answer

Solution code:
from pprint import pprint as pp
import collections
import math
x,y = list(map(int, input().split()))

bai = y/x
if bai==int(bai):
  print(math.ceil(math.log2(bai))+1)
else:
  print(math.floor(math.log2(bai))+1)

Submission status: Wrong Answer

Solution code:
from pprint import pprint as pp
import collections
import math
x,y = list(map(int, input().split()))

bai = y/x
if bai==int(bai):
  print(math.ceil(math.log2(bai))+1)
else:
  print(math.ceil(math.log2(bai)))

Submission status: Wrong Answer

Solution code:
x, y = map(int, input().split())
c = 2
z = 1
if(x > 1):
  c = x
while(c*2 <= y):
  c *= 2
  z += 1
print(z)

Submission status: Wrong Answer

Solution code:
import math
a,b = map(long, raw_input().split())
c= math.floor(math.log(b/a)/math.log(2)+0.000000000001)
print int(c)+1

Submission status: Wrong Answer

Solution code:
x, y = map(int, input().split())
c = 2
z = 1
if(x > 1):
  c = x;
while(c*2 <= y):
  c *= 2;
  z += 1;
print(z)

Submission status: Wrong Answer

Solution code:
import math
a,b = map(long, raw_input().split())
c= math.floor(math.log(b/a)/math.log(2))
print int(c)+1

Submission status: Wrong Answer

Solution code:
import math
a,b = map(long, raw_input().split())
c= math.floor(math.log(b/a)/math.log(2))
print int(c)

Submission status: Wrong Answer

Solution code:
from pprint import pprint as pp
import collections
import math
x,y = list(map(int, input().split()))

bai = y/x
if bai < 0:
    print(math.floor(math.log2(-bai))+2)
else:
    print(math.floor(math.log2(bai))+1)

Submission status: Wrong Answer

Solution code:
import math
a,b = map(long, raw_input().split())
c= math.floor(math.log(b/a)/math.log(2))+1
print int(c)

Submission status: Wrong Answer

Solution code:
import math

s = input().split(" ")
s = [int(i) for i in s]
X = s[0]
Y = s[1]


n = math.log2(Y) - math.log2(X)
print(int(n) + 1)

Submission status: Wrong Answer

Solution code:
# -*- coding: utf-8 -*-
import math,sys

X,Y = map(int,input().split())

n = math.floor(math.log(Y,2)-math.log(X,2))

while X*2**n < Y:
    n = n + 1

print(n)

Submission status: Wrong Answer

Solution code:
from pprint import pprint as pp
import collections
import math
x,y = list(map(int, input().split()))

#pp(y/x)
print(math.floor(math.log2(y/x)+1))

Submission status: Wrong Answer

Solution code:
X, Y = list(map(int, input().split()))

len_list = Y - X + 1

max_len = 0

for idx_1 in range(X, Y):
    len_count = 1
    idx_2 = idx_1
    idx_3 = idx_2 + 1
    while (idx_3 != Y + 1):
        if idx_3 % idx_2 == 0:
            len_count += 1
            idx_2 = idx_3
        idx_3 += 1
    max_len = max(max_len, len_count)

print(max_len)

Submission status: Wrong Answer

Solution code:
import math
from decimal import Decimal

s = input().split(" ")
s = [int(i) for i in s]
X = s[0]
Y = s[1]


n = math.log2(Y) - math.log2(X)
if n >= 1 : 
    print(int(n) + 1)
else : 
    print(1)

Submission status: Wrong Answer

Solution code:
a,b = map(int,input().split())
c = b/a
ans = 0
while c >= 1:
    c = c/2
    ans = ans+1
print(ans)

Submission status: Wrong Answer

Solution code:
# -*- coding: utf-8 -*-
import math,sys

X,Y = map(int,input().split())

print(math.ceil((math.log(Y,10)-math.log(X,10))/math.log(2,10)))

Submission status: Wrong Answer

Solution code:
import math
l2=math.log(2)
A,B=map(int,input().split(' '))
print(math.floor(math.log(B/A)/l2)+1)

Submission status: Wrong Answer

Solution code:
import math
from decimal import Decimal

s = input().split(" ")
s = [int(i) for i in s]
X = s[0]
Y = s[1]


n = math.log2(Decimal(Y) / Decimal(X))
if n >= 1 : 
    print(int(n) + 1)
else : 
    print(1)

Submission status: Wrong Answer

Solution code:
a,b = map(int,input().split())
c = b/a
ans = 1
while c > 2:
    print(c)
    c = c/2
    ans = ans+1
print(ans)

Submission status: Wrong Answer

Solution code:
# -*- coding: utf-8 -*-
import math,sys

X,Y = map(int,input().split())

print(math.ceil(math.log(Y/X)/math.log(2)))

Submission status: Wrong Answer

Solution code:
[X, Y] = map(int, raw_input().split())

print (Y / X)

Submission status: Wrong Answer

Solution code:
# -*- coding: utf-8 -*-
import math,sys

X,Y = map(int,input().split())

print(math.ceil(math.log(Y,2)-math.log(X,2)))

Submission status: Wrong Answer

Solution code:
x, y = map(int, raw_input().split(" "))
count = 2
ans = x * 2
if x == y:
    print 0
else:
    while True:
        ans *= 2
        if ans > y:
            break
        count += 1

    print count

Submission status: Wrong Answer

Solution code:
# -*- coding:utf-8 -*-


def main(min_limit, max_limit):
    result = []
    i = min_limit

    while(i < max_limit + 1):
        result.append(i)
        i = i * 2
    print(len(result))
    print(result)


if __name__ == "__main__":
    min_limit, max_limit = [int(val) for val in input().split()]
    main(min_limit, max_limit)

Submission status: Wrong Answer

Solution code:
import math

s = input().split(" ")
s = [int(i) for i in s]
X = s[0]
Y = s[1]


n = math.log2(Y / X)
if n >= 1 : 
    print(int(n) + 1)
else : 
    print(1)

Submission status: Wrong Answer

Solution code:
x, y = map(int, raw_input().split(" "))
count = 2
ans = x * 2
while True:
    ans *= 2
    if ans > y:
        break
    count += 1

print count

Submission status: Wrong Answer

Solution code:
x, y = map(int, input().split())
n = y/x

cnt = 0
while True:
    if 2**cnt<=n:
        cnt += 1
    else:
        break
print(int(cnt))

Submission status: Wrong Answer

Solution code:

import math

input_line = input().rstrip().split(' ')

X = int(input_line[0])
Y = int(input_line[1])
result = math.floor(math.log(math.floor(Y / X), 2)) + 1

print(result)

Submission status: Wrong Answer

Solution code:
import math

s = input().split(" ")
s = [int(i) for i in s]
X = s[0]
Y = s[1]

if X == Y : 
    print(1)
else :
    n = math.log2(Y / X)
    if n >= 1 : 
        print(int(n) + 1)
    else : 
        print(1)

Submission status: Wrong Answer

Solution code:
x, y = map(int, raw_input().split(" "))
count = 1
ans = x * 2
while True:
    ans *= 2
    count += 1
    if ans > y:
        break

print count

Submission status: Wrong Answer

Solution code:
x, y = map(int, input().split())
c = 2
z = 1
if(x != 1):
  c = x;
while(c*2 <= y):
  c *= 2;
  z += 1;
print(z)

Submission status: Wrong Answer

Solution code:
import math
X, Y = map(int, input().split())
print(math.floor(math.log(Y/X, 2))+1)

Submission status: Wrong Answer

Solution code:
import math

s = input().split(" ")
s = [int(i) for i in s]
X = s[0]
Y = s[1]

if X == Y : 
    print(1)
else :
    n = math.log2(Y / X)
    if n == int(n) : 
        print(int(n))
    else : 
        print(int(n) + 1)

Submission status: Wrong Answer

Solution code:
import math

s = input().split(" ")
s = [int(i) for i in s]
X = s[0]
Y = s[1]


n = math.log2(Y / X)
if n == int(n) : 
    print(int(n))
else : 
    print(int(n) + 1)

Submission status: Wrong Answer

Solution code:
x, y = map(int, input().split())
n = y/x

cnt = 0
while True:
    if 2**cnt<=n:
        cnt += 1
    else:
        break
print(cnt)

Submission status: Wrong Answer

Solution code:
import math
a = list(map(int, input().split()))
b = a[1] / a[0]
c = int(math.log2(b))
print(c+1)

Submission status: Wrong Answer

Solution code:
x,y = map(int,input().split())
counter = 0
for i in range(57):
	if x*2**(i) <= y:
		counter += 1
	else:
		break
print(counter)

Submission status: Wrong Answer

Solution code:
import math

s = input().split(" ")
s = [int(i) for i in s]
X = s[0]
Y = s[1]

if X == Y : 
    print(0)
else : 
    n = int(math.log2(Y / X))
    print(n + 1)

Submission status: Wrong Answer

Solution code:
import math

x, y = map(int, raw_input().split())

t = int(math.floor(y/x))

i = 1
while t > 1:
    i += 1
    t /= 2

print i

Submission status: Wrong Answer

Solution code:
a,b=[int(i) for i in input().split(" ")]
n=0

while a<b:
  a=a*2
  n+=1
print(n)

Submission status: Wrong Answer

Solution code:
import math

s = input().split(" ")
s = [int(i) for i in s]
X = s[0]
Y = s[1]

n = int(math.log2(Y / X))
print(n + 1)

Submission status: Wrong Answer

Solution code:
# coding: utf-8
# Your code here!
import math
X,Y=[int(i) for i in input().split()]

aa = math.floor(math.log2(Y//X)) + 1

print(aa)

Submission status: Wrong Answer

Solution code:
import math
X, Y = map(int, input().split())
print(math.floor(math.log(Y/X)/math.log(2)+1))

Submission status: Time Limit Exceeded

Solution code:
# input
X, Y = map(int, input().split())

# check
res = 0
for a in range(X, Y + 1):
    if Y // a < res:
        break

    seq = [a]
    target = a
    while target <= Y:
        if target not in seq and target % seq[-1] == 0:
            seq.append(target)
        target += seq[-1]

    if res < len(seq):
        res = len(seq)

print(res)

Submission status: Time Limit Exceeded

Solution code:
x,y = map(int,input().split())
maxx = y//x + 1
count = 0
for i in range(maxx):
  if x*(2**i) <= y:
    count += 1
print(count)

Submission status: Time Limit Exceeded

Solution code:
X,Y = map(int,input().split())
li = []
for i in range(X,(Y+1)):
    temp = i
    if temp%X ==0 :
        li.append(i)
        X = temp 
print(len(li))

Submission status: Time Limit Exceeded

Solution code:
X,Y = map(int,input().split())
count = 1

while True:
  if X*2 <= Y:
    count +=1
    X = X*2
    
print(count)

Submission status: Time Limit Exceeded

Solution code:
x,y = map(int,input().split())
d = y//x
ans = 0
while 0 < d:
  ans += 1
  d // 2
print(ans)

Submission status: Time Limit Exceeded

Solution code:
X,Y = map(int, input().split())

a = X
A = []
A.append(a)

flg = 0
count = 2
while flg!=1:
    e = count*a
    if e>Y:
        flg = 1
        break
    count = count + 1
    if e%A[len(A)-1]==0:
        A.append(e)

print(len(A))

Submission status: Time Limit Exceeded

Solution code:
X,Y = map(int,input().split())
k = []
A = X
for i in range(10**18):
  A = A*i
  k.append(A)
print(max(A))

Submission status: Time Limit Exceeded

Solution code:
x, y = map(int,input().split())
a = []
a.append(x)
for i in range(x+1,y+1):
    if i % x == 0:
        a.append(i)
        x = i
print(len(a))

Submission status: Time Limit Exceeded

Solution code:
while True:
    A = []
    s = 0
    a = input().split()
    X, Y = list(map(int,list(a)))
    if X > Y or Y > 10**18 or X < 1:
        continue
    A.append(X)
    for i in range(2*X,Y+1):
        if i == A[len(A)-1]*2:
            A.append(i)
    s = len(A)
    if A[len(A)-1] > Y:
        s = len(A) -1
    print(s)
    break

Submission status: Time Limit Exceeded

Solution code:
x,y = map(int,input().split())
count = 1
counts = []
an = 0

for i in range(x,y+1):
  an = i
  for j in range(i+1,y+1):
    
    if j % an == 0:
      count += 1
      an = j
  counts.append(count)
  count = 0
  
print(max(counts))

Submission status: Time Limit Exceeded

Solution code:
x,y = map(int,input().split())
nums = []
n = 0
for i in range(x,y + 1):
    if i == x * pow(2,n) and i <= y:
        nums.append(i)
        n += 1
print(len(nums))

Submission status: Time Limit Exceeded

Solution code:
X,Y = map(int, input().split())

j=0
d=[]
d.append(X)
for i in range(X+1,Y+1):
    if i%d[j]==0:
        d.append(i)
        j+=1

print(len(d))

Submission status: Time Limit Exceeded

Solution code:
def amari(num, div):
    if num < div:
        return num
    elif num == div:
        return 0
    else:
        return amari(num-div, div)

[X, Y] = map(int, raw_input().split())
#print X, Y

# A : X <= int <= Y
# Ai+1 = mult(Ai,n) => Ai+1 / Ai = 0
# Ai+1 > Ai

Ai = X
i = X+1
length = 1
while i <= Y:
#    print i, Ai, length
    ret = amari(i, Ai)
    if ret == 0:
        length = length + 1
        Ai = i
#        print length

    i = i+1

print length

Submission status: Time Limit Exceeded

Solution code:
def main():
    X, Y = map(int, input().split())
    c = 0
    for i in range(X, Y + 1, X):
        if i % X == 0:
            c += 1
            X = i

    print(c)


if __name__ == "__main__":
    main()

Submission status: Time Limit Exceeded

Solution code:
def main():
    X, Y = map(int, input().split())
    c = 0
    tmp = X
    for i in range(X, Y + 1, X):
        if i % tmp == 0:
            c += 1
            tmp = i

    print(c)


if __name__ == "__main__":
    main()

Submission status: Time Limit Exceeded

Solution code:
def main():
    X, Y = map(int, input().split())
    c = 0
    tmp = X
    for i in range(X, Y + 1):
        if i % tmp == 0:
            c += 1
            tmp = i
            
    print(c)


if __name__ == "__main__":
    main()

Submission status: Accepted

Solution code:
x,y=map(int,input().split())
cnt=0
while x<=y:
  x=x*2
  cnt+=1
print(cnt)

Submission status: Accepted

Solution code:
x, y = map(int, input().split())
n = 0
while x <= y:
    x += x
    n += 1
print(n)

Submission status: Accepted

Solution code:
x,y = map(int, input().split())

cnt = 0
a = x
while a <= y:
    a += a
    cnt += 1
print(cnt)