Problem:
 Score: 200 points    Problem Statement  M-kun has the following three cards:   A red card with the integer A .  A green card with the integer B .  A blue card with the integer C .   He is a genius magician who can do the following operation at most K times:   Choose one of the three cards and multiply the written integer by 2 .   His magic is successful if both of the following conditions are satisfied after the operations:   The integer on the green card is strictly greater than the integer on the red card.  The integer on the blue card is strictly greater than the integer on the green card.   Determine whether the magic can be successful.      Constraints   1 \leq A, B, C \leq 7  1 \leq K \leq 7  All values in input are integers.         Input  Input is given from Standard Input in the following format:  A  B  C  K       Output  If the magic can be successful, print Yes ; otherwise, print No .        Sample Input 1 7 2 5
3      Sample Output 1 Yes  The magic will be successful if, for example, he does the following operations:   First, choose the blue card. The integers on the red, green, and blue cards are now 7 , 2 , and 10 , respectively.  Second, choose the green card. The integers on the red, green, and blue cards are now 7 , 4 , and 10 , respectively.  Third, choose the green card. The integers on the red, green, and blue cards are now 7 , 8 , and 10 , respectively.        Sample Input 2 7 4 2
3      Sample Output 2 No  He has no way to succeed in the magic with at most three operations.

Solution (Python):
a, b, c = map(int, input().split())
k =int(input())
n=0
while a >= b:
    b=b*2
    n+=1
while b >= c:
    c=c*2
    n+=1
print('Yes' if n<=k else 'No')

Solution (Python):
a, b, c = map(int, input().split())
k = int(input())

cnt = 0

while b <= a:
  b *= 2
  cnt += 1

while c <= b:
  c *= 2
  cnt += 1
if cnt <= k:
  print ('Yes')
else:
  print ('No')

Solution (Python):
x=input()
x0=x.split()
a=int(x0[0])
b=int(x0[1])
c=int(x0[2])
k=int(input())
q=0
while a>=b:
    q+=1
    b*=2
while b>=c:
    q+=1
    c*=2
if q<=k:
    print("Yes")
else:
    print("No")

Solution (Python):
import sys
input = sys.stdin.readline



A, B, C = (int(i) for i in input().split())
K = int(input())

while K > 0:
    if A < B and B < C:
        print("Yes")
        exit()
    elif A < B:
        C = C*2
    else:
        B = B*2
    K -= 1

if A < B and B < C:
        print("Yes")
        exit()
print("No")

Solution (Python):
A, B, C = map(int, input().split())
K = int(input())

for i in range(K+1):
    j = K - i
    b = B * 2 ** i
    c = C * 2 ** j
    if b > A and c > b:
        print("Yes")
        break
else:
    print("No")

Solution (Python):
a,b,c=map(int,input().split())
k=int(input())
for i in range(k+1):
  if a< b<c:
    print("Yes")
    exit()
  else:
    if a >= b:
      b *= 2
    else:
      c *= 2
print("No")

Solution (Python):
import sys
input=sys.stdin.readline
sys.setrecursionlimit(10 ** 8)
from itertools import accumulate
from itertools import permutations
from itertools import combinations
from collections import defaultdict
from collections import Counter
import fractions
import math
from collections import deque
from bisect import bisect_left
from bisect import bisect_right
from bisect import insort_left
import itertools
from heapq import heapify
from heapq import heappop
from heapq import heappush
import heapq
from copy import deepcopy
from decimal import Decimal
alf = list("abcdefghijklmnopqrstuvwxyz")
ALF = list("ABCDEFGHIJKLMNOPQRSTUVWXYZ")

INF = float("inf")


A,B,C = map(int,input().split())
K = int(input())
flag = 0
while K > 0:
    if A < B and B < C:
        flag = 1
        break
    if A >= B:
        B *= 2
        K -= 1
    elif B >= C:
        C *= 2
        K -= 1
if flag == 1:
    print("Yes")
else:
    if A < B and B < C:
        print("Yes")
    else:
        print("No")

Solution (Python):
A,B,C=map(int,input().split())
K=int(input())


for _ in range(K):
  if A>=B:
    B*=2
  elif B>=C:
    C*=2

if B>A and C>B:
  print('Yes')
else:
  print('No')

Solution (Python):
r,g,b=map(int, input().split())
m =int(input())
ans = 0
while g<=r:
  g*=2
  ans+=1
while b<=g:
  b*=2
  ans+=1
if ans<=m:
  print("Yes")
else:
  print("No")

Solution (Python):
A, B, C = map(int, input().split())
K = int(input())

while A >= B:
    K -= 1
    B *= 2

while B >= C:
    K -= 1
    C *= 2

if K >= 0:
    print('Yes')
else:
    print('No')

Solution (Python):
a, b, c = map(int, input().split())
k = int(input())

while k:
    if not a < b:
        b *= 2
        k -= 1
        continue
    elif not b < c:
        c *= 2
        k -= 1
        continue
    else:
        break


if a < b < c:
    print('Yes')
else:
    print('No')

Solution (Python):
import itertools
A,B,C=map(int,input().split())
K=int(input())
for seq in itertools.product(range(3),repeat=K):
    a,b,c=A,B,C
    for i in range(K):
        if seq[i]==0:
            a=a*2
        elif seq[i]==1:
            b=b*2
        else:
            c=c*2
    if b>a and c>b:
        print("Yes")
        exit()
print("No")

Solution (Python):
a,b,c=map(int,input().split())
k=int(input())

def dfs(a,b,c,k):
    if k==0:
        if a<b<c:
            print("Yes")
            exit()
    else:
        dfs(a,2*b,c,k-1)
        dfs(a,b,2*c,k-1)
dfs(a,b,c,k)
print("No")

Solution (Python):
A, B, C=map(int, input().split())
K=int(input())
i=0
while i<K:
  if B<=A:
    B*=2
  elif C<=B:
    C*=2
  i+=1
    
if A<B<C:
  print('Yes')
else:
  print('No')

Solution (Python):
def main():
    A,B,C = list(map(int, input().split(' ')))
    K = int(input())
    
    P=[A,B,C]
    for k in range(K):
        if not (P[1] >P[0]):
            P[1] = P[1] * 2
        elif not (P[2] >P[1]):
            P[2] = P[2] * 2
            
    if P[0] < P[1] < P[2]:
        print('Yes')
    else:
        print('No')
        
        
    
    

main()

Solution (Python):
import sys
read = sys.stdin.read
readline = sys.stdin.readline
readlines = sys.stdin.readlines

def main():
    a,b,c = map(int, readline().split())
    K = int(readline())

    for i in range(K):
        if a >= b:
            b *= 2
        else:
            if b >= c:
                c *= 2
    
    if a < b < c:
        print("Yes")
    else:
        print("No")


if __name__ == "__main__":
    main()

Solution (Python):
def main():
    a,b,c = map(int,input().split())
    k = int(input())

    cnt = 0
    while b<=a:
        b=b*2
        cnt +=1
    while c<=b:
        c=c*2
        cnt += 1
    if cnt>k:
        print('No')
    else:
        print('Yes')
        

if __name__ == "__main__":
    main()

Solution (Python):
a, b, c = map(int, input().split())
k = int(input())

while a >= b:
    b *= 2
    k -= 1

while b >= c:
    c *= 2
    k -= 1

if 0 <= k:
    print("Yes")
else:
    print("No")

Solution (Python):
A,B,C=list(map(int,input().split()))
K = int(input())
while K > 0:
  if A>=B:
    B*=2
  elif B>=C:
    C*=2
  K -= 1
print('Yes' if A<B<C else 'No')

Solution (Python):
a,b,c=map(int,input().split())
k=int(input())
ans=0
while a>=b:
    ans+=1
    b*=2
while b>=c:
    ans+=1
    c*=2
print("Yes" if ans<=k else "No")

Solution (Python):
a,b,c=map(int,input().split())
k=int(input())

while a>=b:
    b=b*2
    k=k-1

while b>=c:
    c=c*2
    k=k-1

if k<0:
    print("No")
if k>=0:
    print("Yes")

Solution (Python):
a,b,c,k=map(int,open(0).read().split())
while a>=b:
    k-=1
    b*=2
while b>=c:
    k-=1
    c*=2
print("Yes" if k>=0 else "No")

Solution (Python):
A, B, C = map(int, input().split())
K = int(input())

for k in range(K):
    if B <= A:
        B *= 2
    elif C <= B:
        C *= 2
        
if A < B and B < C:
    print('Yes')
else:
    print('No')

Solution (Python):


def count(A, B, C):
    ret = 0
    while B <= A:
        B *= 2
        ret += 1
    while C <= B:
        C *= 2
        ret += 1
    return ret
    
A, B, C = input().split(' ')
K = int(input())

A = int(A)
B = int(B)
C = int(C)

if count(A, B, C) <= K:
    print("Yes")
else:
    print("No")

Solution (Python):
a, b, c = map(int, input().split())
k = int(input())
cnt = 0
while a >= b:
    b *= 2
    cnt += 1
while b >= c:
    c *= 2
    cnt += 1
if cnt <= k:
    print("Yes")
else:
    print("No")

Solution (Python):
a,b,c=map(int, input().split())
k=int(input())
co=0
while not (a<b and b<c):
  if co == k:
    print('No')
    break
  if not a<b:
    b*=2
  else:
    c*=2
  co+=1
  
else:
  print('Yes')

Solution (Python):
import heapq
t = 1
def max(a,b):
	if a > b:
		return a
	return b
while t > 0:
	t -= 1
	a,b,c = map(int,input().split())
	k = int(input())
	
	
	
	while k > 0 and a >= b:
		b *= 2
		k -= 1
	while k > 0 and b >= c:
		c *= 2
		k -= 1
	
	
	
	
	if a < b and b < c:
		print("Yes")
	else:
		print("No")

Solution (Python):
a,b,c=map(int,input().split())
k=int(input())
for i in range(k):
    if b<=a: b*=2
    elif c<=b: c*=2
if a<b<c: print('Yes')
else: print('No')

Solution (Python):
A, B, C = map(int, input().split())
K = int(input())

while A >= B and K > 0:
    K -= 1
    B *= 2
while B >= C and K > 0:
    K -= 1
    C *= 2


if (A < B) and (B < C):
    print('Yes')
else:
    print('No')

Solution (Python):
a,b,c=map(int,input().split())
k=int(input())

count=0
while b<=a:
    count+=1
    b*=2

while c<=b:
    count+=1
    c*=2

if count<=k:
    print('Yes')
else:
    print('No')

Solution (Python):
A,B,C=map(int, input().split())
K=int(input())
for i in range(K):
  if A>=B:
    B*=2
  else:
    C*=2
if A<B and B<C:
  print('Yes')
else:
  print('No')

Solution (Python):



def mp(): return map(int, input().split())
def lmp(): return list(map(int, input().split()))

a = lmp()
k = int(input())
while k != 0:
    k -= 1
    for i in range(1,3):
        if a[i-1] >= a[i]:
            a[i] *= 2
            break
if a[0] < a[1] < a[2]:
    print("Yes")
else:
    print("No")

Solution (Python):
A, B, C = map(int, input().split())
K = int(input())

count=0

for i in range (0, 100):
    if B <= A:
        B = B*2
        count+= 1
    if C <= B:
        C = C*2
        count+=1

if count <= K:
    print('Yes')
else:
    print('No')

Solution (Python):


import copy
import random
import bisect 
import fractions 
import math
import sys
import collections
from decimal import Decimal 

mod = 10**9+7
sys.setrecursionlimit(mod) 

d = collections.deque()
def LI(): return list(map(int, sys.stdin.readline().split()))

A, B, C = LI()
K = int(input())

for k in range(K):
    if A < B:
        C *= 2
    else:
        B *= 2

if A < B and B < C:
    print("Yes")
else:
    print("No")

Solution (Python):
a, b, c, k = map(int, open(0).read().split())
for i in range(k):
    if a >= b:
        b *= 2
        continue
    if b >= c:
        c *= 2
if a < b < c:
    print('Yes')
else:
    print('No')

Solution (Python):
A,B,C = map(int,input().split())
K = int(input())
ans = 0
while A>=B:
    ans+=1
    B*=2
while B>=C:
    ans+=1
    C*=2
if ans<= K:
    print('Yes')
else:
    print('No')

Solution (Python):
A,B,C=map(int, input().split())
K=int(input())

for i in range(K):
    if B <= A:
        B*=2
    else:
        C*=2

if B > A and C > B:
    print("Yes")
else:
    print("No")

Solution (Python):
A,B,C=map(int,input().split())
K=int(input())
count=0

while A>=B:
  B*=2
  count+=1
  
while B>=C:
  C*=2
  count+=1  
  
print("Yes" if count<=K else "No")

Solution (Python):
def main():
    import sys
    A,B,C=list(map(int,sys.stdin.readline().split()))
    K=int(sys.stdin.readline())
    for i in range(K+1):
        if B<=A:
            B*=2
        elif C<=B:
            C*=2
        else:
            print('Yes')
            return

    print('No')

main()

Solution (Python):
A, B, C = map(int, input().split())
K = int(input())

while K > 0 and B <= A:
    B *= 2
    K -= 1

while K > 0 and C <= B:
    C *= 2
    K -= 1

if C > B > A:
    print('Yes')
else:
    print('No')

Solution (Python):
a,b,c=map(int,input().split())
k=int(input())

for i in range(k):
    if a>=b:
        b=b*2
    elif a<b:
        c=c*2
else:
    if a<b<c:
        print('Yes')
    else:
        print('No')

Solution (Python):
A,B,C = map(int,input().split())
K = int(input())

cnt = 0
while A >= B:
    B *= 2
    cnt += 1

while B >= C:
    C *= 2
    cnt += 1

if cnt <= K:
    print("Yes")
else:
    print("No")

Solution (Python):
A, B, C = map(int, input().split())

K = int(input())

while True:
  if B <= A:
    B *= 2
    K -= 1
  else:
    break
    
while True:
  if C <= B:
    C *= 2
    K -= 1
  else:
    break

if K >= 0:
  print('Yes')
else:
  print('No')

Solution (Python):
A,B,C,K = map(int, open(0).read().split())
count = 0
while B <= A:
    if count < K:
        count += 1
        B *= 2
    else:
        print('No')
        break
else:
    while C <= B:
        if count < K:
            count += 1
            C *= 2
        else:
            print('No')
            break
    else:
        print('Yes')

Solution (Python):

import sys  
input = sys.stdin.readline


A,B,C = list(map(int,input().split()))
K= int(input())

cnt = 0
while B<=A:
    B *= 2
    cnt +=1
while C<=B:
    C *=2
    cnt +=1
print('Yes' if cnt <=K else 'No')

Solution (Python):
A,B,C=map(int,input().split())
K=int(input())
while A>=B:
  K-=1
  B*=2
while B>=C:
  K-=1
  C*=2
if K>=0:
  print('Yes')
else:
  print('No')

Solution (Python):






A,B,C = map(int, input().split())
K = int(input())





cnt = 0
a,b,c = A,B,C
while a >= b:
    b *= 2
    cnt += 1
while b >= c:
    c *= 2
    cnt += 1
if cnt <= K:
    print("Yes")
else:
    print("No")

Solution (Python):

import sys;input = sys.stdin.readline
inp,ip = lambda :int(input()),lambda :[int(w) for w in input().split()]

a,b,c = ip()
k = inp()

ct = 0
while b <= a:
    b *= 2
    ct += 1
while c <= b:
    c *= 2
    ct += 1

if ct <= k:
    print("Yes")
else:
    print("No")

Solution (Python):
A, B, C = map(int, input().split())
K = int(input())

for k in range(K):
    if B <= A:
        B *= 2
    elif C <= B:
        C *= 2

if A < B < C:
    print('Yes')
else:
    print('No')

Solution (Python):
LI = lambda: list(map(int, input().split()))

A, B, C = LI()
K = int(input())


def main():
    a, b, c = A, B, C
    for _ in range(K):
        if a >= b:
            b *= 2
        elif b >= c:
            c *= 2
    if a < b < c:
        ans = "Yes"
    else:
        ans = "No"
    print(ans)


if __name__ == "__main__":
    main()

Solution (Python):
a,b,c = map(int, input().split())
k = int(input())

for _ in range(k):
    if a >= b:
        b *= 2
    elif b >= c:
        c*=2

if a < b < c:
    print('Yes')
else:
    print('No')

Solution (Python):
a,b,c = map(int,input().split())
k = int(input())



for i in range(k):
  if b <= a:
    b *= 2
  elif c <= b:
    c *= 2

if b > a and c > b:
  print("Yes")
else:
  print("No")

Solution (Python):



def main():
    a, b, c = map(int, input().split())
    K = int(input())

    while K > 0:
        if a < b:
            break
        
        b *= 2
        K -= 1
    
    while K > 0:
        if b < c:
            break

        c *= 2
        K -= 1
    
    if a < b < c:
        return "Yes"
    else:
        return "No"


print(main())

Solution (Python):
A, B, C = map(int, input().split())
K = int(input())

for i in range(K):
    if A >= B:
        B *= 2
    elif B >= C:
        C *= 2

if A < B and B < C:
    print("Yes")
else:
    print("No")

Solution (Python):
A, B, C = map(int, input().split())
K = int(input())
for i in range(K):
  if A >= C or B >= C:
    C *= 2
  elif A >= B:
    B *= 2
if A < B < C:
  print("Yes")
else:
  print("No")

Solution (Python):
import sys


def main():
    input = sys.stdin.buffer.readline
    a, b, c = map(int, input().split())
    k = int(input())
    cnt = 0
    while a >= b:
        b *= 2
        cnt += 1
    while b >= c:
        c *= 2
        cnt += 1
    print("Yes" if cnt <= k else "No")


if __name__ == "__main__":
    main()

Solution (Python):
r, g, b = map(int, input().split())
k = int(input())

for i in range(k):
    if r >= g:
        g *= 2
    elif g >= b:
        b *= 2

if r < g < b:
    print("Yes")
else:
    print("No")

Solution (Python):
def main():

    A, B, C = map(int, input().split())
    K = int(input())
    for i in range(K+1):
        for j in range(K+1):
            for l in range(K+1):
                if i + j + l <= K:
                    x = A * pow(2, i)
                    y = B * pow(2, j)
                    z = C * pow(2, l)
                    if x < y and y < z:
                        return "Yes"
    return "No"

if __name__ == '__main__':
    print(main())

Solution (Python):
A, B, C = map(int, input().split())

K = int(input())

c = 0

while True:
    if A >= B:
        B *= 2
        c += 1
    elif B >= C:
        C *= 2
        c += 1
    else:
        break

if c <= K:
    print("Yes")

else:
    print("No")

Solution (Python):
A, B, C = map(int, input().split())
K = int(input())

k = 0
while A >= B:
    B *= 2
    k += 1
while B >= C:
    C *= 2
    k += 1
print('Yes' if k <= K else 'No')

Solution (Python):
A,B,C = map(int,input().split())
K = int(input())
for i in range(K):
    if A >= B:
        B *= 2
    else:
        C *= 2
if A < B < C:
    print('Yes')
else:
    print('No')

Solution (Python):
a,b,c=map(int,input().split())
k=int(input())
cnt=0
while a>=b:
  b*=2
  cnt+=1
while b>=c:
  c*=2
  cnt+=1
if k>=cnt:
  print("Yes")
else:
  print("No")

Solution (Python):
def main():
    a, b, c = list(map(int, input().split()))
    k = int(input())

    cnt = 0
    while True:
        if b > a:
            break
        cnt += 1
        b *= 2

    while True:
        if c > b:
            break
        cnt += 1
        c *= 2
    
    if cnt <= k:
        print("Yes")
    else:
        print("No")


if __name__ == "__main__":
    main()

Solution (Python):
a, b, c = map(int, input().split())
k = int(input())

d = 0
while d < k:
    if a >= b:
        b *= 2
    elif b >= c:
        c *= 2
    d += 1
if a < b and b < c:
    print('Yes')
else:
    print('No')

Solution (Python):

a, b, c, k = map(int, open(0).read().split())
while a >= b:
    b *= 2
    k -= 1
while b >= c:
    c *= 2
    k -= 1
print("YNeos"[k < 0::2])

Solution (Python):
a,b,c = map(int, input().split())
k = int(input())

for i in range(k):
    if a<b:
        c *=2
    else:
        b*=2

if a<b and b<c:
    print("Yes")
else:
    print("No")

Solution (Python):
a,b,c = map(int,input().split())
k = int(input())

for i in range(k):
    if(a >= b):
        b *= 2
    else:
        c *= 2

if(a < b and b < c):
    print('Yes')
else:
    print('No')

Solution (Python):
import sys
input = sys.stdin.readline



def main():
    A, B, C = map(int, input().split())
    K = int(input())

    for _ in range(K):
        if A >= B:
            B *= 2
        elif B >= C:
            C *= 2
    
    if A < B and B < C:
        print("Yes")
    else:
        print("No")


if __name__ == '__main__':
    main()

Solution (Python):
a,b,c=map(int,input().split())
k=int(input())

while b<=a and k>0:
    b*=2
    k-=1

while c<=b and k>0:
    c*=2
    k-=1

if b>a and c>b:
    print('Yes')
else:
    print('No')

Solution (Python):
import sys

a, b, c = map(int, input().split())
k = int(input())
kk = 0
while a >= b:
	b *= 2
	kk += 1

while b >= c:
	c *= 2
	kk += 1

if kk <= k:
	print("Yes")

else:
	print("No")

Solution (Python):
A, B, C = map(int, input().split())

K = int(input())
while(K > 0 and A >= B):
    B *= 2
    K -= 1

while(K > 0 and B >= C):
    C *= 2
    K -= 1

if A < B < C:
    print("Yes")

else:
    print("No")

Solution (Python):
r, g , b = map(int, input().split())
k = int(input())
while(g <= r):
	g *= 2
	k -= 1
while(b <= g):
	b *= 2
	k -= 1
if k >= 0:
	print("Yes")
else:
	print("No")

Solution (Python):
A, B, C = map(int, input().split())
K = int(input())
b = B
c = C

cnt = 0
while A >= b:
    b *= 2
    cnt += 1
    
while b >= c:
    c *= 2
    cnt += 1

if(cnt <= K):
    print("Yes")
else:
    print("No")

Solution (Python):
a,b,c=map(int,input().split())
k=int(input())
cnt=0
while not a<b:
    b=2*b
    cnt+=1
while not b<c:
    c=2*c
    cnt+=1
if cnt>k:
    print("No")
else:
    print("Yes")

Solution (Python):
r,g,b = map(int, input().split())
k = int(input())

count = 0
while g <= r:
    count += 1
    g *= 2

while b <= g:
    count += 1
    b *= 2

if count <= k:
    print('Yes')
else:
    print('No')

Solution (Python):
a, b, c = map(int, input().split())
k = int(input())

cnt = 0
while b <= a:
    b *= 2
    cnt += 1
while c <= b:
    c *= 2
    cnt += 1
print("Yes" if cnt <= k else "No")

Solution (Python):
a,b,c = map(int, input().split())
k = int(input())
cnt = 0
while a>=b:
    b *= 2
    cnt += 1
while b>=c:
    c *= 2
    cnt += 1
print("YNeos"[cnt>k::2])

Solution (Python):
A, B, C = map(int, input().split())
K = int(input())

b = 0
while (b <= K and A >= 2**b * B):
    b += 1

if 2**b * B < 2**(K-b) * C:
    print("Yes")
else:
    print("No")

Solution (Python):
a,b,c = map(int,input().split())
K = int(input())
ans = "No"
for i in range(K+1):
    for j in range(K+1-i):
        for k in range(K+1-i-j):
            if a*2**i < b*2**j < c*2**k:
                ans = "Yes"
                break
print(ans)

Solution (Python):
a, b, c = map(int, input().split())
k = int(input())

cnt = 0
while b <= a:
    b *= 2
    cnt += 1
while c <= b:
    c *= 2
    cnt += 1

if cnt <= k:
    print('Yes')
else:
    print('No')

Solution (Python):
R = 0
G = 1
B = 2


def check(ns):
    return ns[G] > ns[R] and ns[B] > ns[G]

def solve(ns, k):
    if check(ns):
        return True
    if k == 0:
        return False
    for i in xrange(3):
        ms = ns[:]
        ms[i] *= 2
        if solve(ms, k - 1):
            return True
    return False


assert solve([7, 2, 5], 3) == True
assert solve([7, 4, 2], 3) == False


ns = map(int, raw_input().split())
k = int(raw_input())

print 'Yes' if solve(ns, k) else 'No'

Solution (Python):
a,b,c=map(int,input().split())
k=int(input())
for _ in range(k):
    if a>=b:
        b*=2
    elif b>=c:
        c*=2
    if a<b<c:
        print('Yes')
        exit()
print('No')

Solution (Python):
A, B, C = map(int, input().split())
K = int(input())
ans = False
for i in range(K+1):
    j = K - i
    B_i = B*(2**i)
    C_i = C*(2**j)
    if A < B_i and B_i < C_i:
        ans = True

if ans:
    print('Yes')
else:
    print('No')

Solution (Python):
def main():
    r,g,b = map(int, input().split())
    k=int(input())
    for _ in range(k):
        if r >= g:
            g *= 2
        elif g >= b:
            b *= 2
        else:
            break
    print("Yes" if r<g<b else "No")

if __name__ == '__main__':
    main()

Solution (Python):
a, b, c = map(int, input().split())
k = int(input())

for i in range(k):
    if a >= b:
        b *= 2
    else:
        c *= 2

if a < b and b < c:
    print('Yes')
else:
    print('No')

Solution (Python):
A,B,C = list(map(int,input().split()))
K = int(input())
out = "No"
while K > 0:
    if B<=A:
        B = B*2
    elif C<=B:
        C = C*2
    if C>B>A:
        out = "Yes"
    K = K-1

print(out)

Solution (Python):
def main():
    A,B,C=map(int,input().split())
    K=int(input()) 
    for _ in range(K):
        if not A<B: 
            B *=2
            continue
        if not B < C:
            C *=2
            continue
        break
    if A<B<C:
        print("Yes")
    else:
        print("No")

main()

Solution (Python):
A,B,C = map(int,input().split())
K = int(input())
count = 0
while B <= A:
    B *= 2
    count += 1
while C <= B :
    C *= 2
    count += 1
if count > K :
    print("No")
else:
    print("Yes")

Solution (Python):
A, B, C = map(int, input().split())
K = int(input())

num = 0
while A >= B:
    B *= 2
    num += 1

while B >= C:
    C *= 2
    num += 1


if num <= K:
    print('Yes')
else:
    print('No')

Solution (Python):
a, b, c = map(int, input().split())
k = int(input())
n = 0
while True:
    if b <= a:
        b *= 2
        n += 1
    else:
        break
while True:
    if c <= b:
        c *= 2
        n += 1
    else:
        break
if k >= n:
    print('Yes')
else:
    print('No')

Solution (Python):
from itertools import product
a, b, c = list(map(int, input().split()))
k = int(input())
for bit in product([0, 1, 2, 3], repeat=k):
    aa, bb, cc = [a, b, c][:]
    for t in bit:
        if t == 0:
            pass
        elif t == 1:
            aa *= 2
        elif t == 2:
            bb *= 2
        elif t == 3:
            cc *= 2
    if aa < bb < cc:
        print('Yes')
        exit()
print('No')

Solution (Python):



from fractions import gcd
from itertools import combinations,permutations,accumulate 

from collections import deque,defaultdict,Counter
import decimal
import re












import sys
sys.setrecursionlimit(10000000)
mod = 10**9 + 7

def readInts():
  return list(map(int,input().split()))
def I():
  return int(input())
a,b,c = readInts()
k = I()
for i in range(k):
    if a < b < c:
        print('Yes')
        exit()

    if a >= b:
        b *= 2
    elif b >= c:
        c *= 2
    
if a < b < c:
    print('Yes')
    exit()
else:print('No')

Solution (Python):
a, b, c = map(int, input().split())
k = int(input())

ans = 0

while a >= b:
  ans += 1
  b *= 2

while b >= c:
  ans += 1
  c *= 2

print("Yes" if ans <= k else "No")

Solution (Python):
b = list(map(int, input().split()))
K = int(input())
for i in range(3 ** K):
    a = b[::]
    for j in range(K):
        a[i % 3] *= 2
        i //= 3
    if a[0] < a[1] and a[1] < a[2]:
        print('Yes')
        exit()
print('No')

Solution (Python):
import sys
sys.setrecursionlimit(10**9)

def mi(): return map(int,input().split())
def ii(): return int(input())
def isp(): return input().split()
def deb(text): print("-------\n{}\n-------".format(text))

INF=10**20
def main():
    A,B,C=mi()
    K=ii()

    def f(X,Y,Z,k):
        if X < Y < Z: return True
        elif k == 0: return False

        return f(X*2,Y,Z,k-1) or f(X,Y*2,Z,k-1) or f(X,Y,Z*2,k-1)
    
    ans = f(A,B,C,K)
    print("Yes" if ans else "No")




if __name__ == "__main__":
    main()

Solution (Python):
A, B, C = map(int, input().split())
K = int(input())

while K>=0:
    if A>=B:
        B *= 2
    elif B>=C:
        C *= 2
    else:
        print("Yes")
        exit()
    K -= 1
print("No")

Solution (Python):
A,B,C = map(int,input().rstrip().split(" "))
K = int(input())
ans = False
for i in range(K):
    if A >= B:B *= 2
    elif B >= C:C *= 2
    else:
        ans = True
        break
if A < B < C:ans = True
if ans:print("Yes")
else:print("No")

Solution (Python):

import sys

YES = "Yes"  
NO = "No"  


def solve(A: int, B: int, C: int, K: int):
    k = 0
    while A >= B:
        k += 1
        B *= 2
    while B >= C:
        k += 1
        C *= 2
    return YES if k <= K else NO


def main():
    def iterate_tokens():
        for line in sys.stdin:
            for word in line.split():
                yield word
    tokens = iterate_tokens()
    A = int(next(tokens))  
    B = int(next(tokens))  
    C = int(next(tokens))  
    K = int(next(tokens))  
    print(solve(A, B, C, K))

def test():
    import doctest
    doctest.testmod()

if __name__ == '__main__':
    
    main()

Solution (Python):
a, b, c = map(int, input().split())
k = int(input())

while a >= b:
    k -= 1
    b *= 2
while b >= c:
    k -= 1
    c *= 2
if k >= 0:
    print('Yes')
else:
    print('No')

Solution (Python):
a,b,c = map(int,input().split())
k = int(input())
cnt = 0
while a>=b:
    cnt +=1
    b*=2
while b>=c:
    cnt += 1
    c*=2
print('Yes' if cnt<=k else 'No')

Solution (Python):
A, B, C = map(int, input().split())
K = int(input())

cnt = 0
while A >= B:
  B *= 2
  cnt += 1
while B >= C:
  C *= 2
  cnt += 1

if cnt <= K:
  print('Yes')
else:
  print('No')

Solution (Python):
abc=input("").split(" ")
a=int(abc[0])
b=int(abc[1])
c=int(abc[2])
k=int(input(""))
s=0
while(b<=a):
    s+=1
    b*=2
while(c<=b):
    s+=1
    c*=2
if(s<=k):
    print("Yes")
else:
    print("No")

Solution (Python):
a, b, c = map(int, input().split())
k = int(input())
for _ in range(k):
  if a >= b:
    b *= 2
  else:
    c *= 2
  if a < b and b < c:
    print('Yes')
    break
else:
  print('No')

Solution (Python):
A, B, C = map(int,input().split())
K = int(input())

for k in range(K):
  
  if A >= B:
    B*=2
  else:
    C*=2


ans = False
if A < B < C:
  ans = True
  
print("Yes" if ans else "No")

Solution (Python):
a, b, c = map(int, input().split())
k = int(input())
while b <= a:
    k -= 1
    b *= 2
while c <= b:
    k -= 1
    c *= 2
print("Yes" if k>=0 else "No")

Solution (Python):
import sys
def rs(): return sys.stdin.readline().rstrip()
def ri(): return int(rs())
def rs_(): return [_ for _ in rs().split()]
def ri_(): return [int(_) for _ in rs().split()]

A, B, C = ri_()
K = ri()
cnt = 0
while 1:
    if A >= B:
        B *= 2
        cnt += 1
    elif B >= C:
        C *= 2
        cnt += 1
    else:
        break
print('Yes' if cnt <= K else 'No')

Solution (Python):
A, B, C = list(map(int,input().split()))
K = int(input())
cnt = K
while(B <= A):
    K -= 1
    B *= 2
while(C <= B):
    K -= 1
    C *= 2
if K >= 0:  print("Yes")
else:  print("No")

Solution (Python):
a,b,c=map(int,input().split())
k=int(input())
x=0
while b<=a:
    b=b<<1
    x+=1
while c<=b:
    c=c<<1
    x+=1
if x<=k:
    print("Yes")
else:
    print("No")

Solution (Python):
a, b, c = map(int, input().split())
k = int(input())

for i in range(k+1):
    for j in range(k+1):
        if i+j > k:
            continue
        l = k-i-j
        A = a*(2**i)
        B = b*(2**j)
        C = c*(2**l)
        if A < B and B < C:
            print('Yes')
            exit()
else:
    print('No')

Solution (Python):
r, g, b = [int(i) for i in input().split()]
K = int(input())


cnt = 0
while g <= r:
  g *= 2
  cnt += 1
  

while b <= g:
  b *= 2
  cnt += 1

  
if K < cnt:
  print("No")
else:
  print("Yes")

Solution (Python):
a,b,c=map(int,input().split())
k=int(input())
cnt=0
while b<=a:
	b*=2
	cnt+=1
while c<=b:
	c*=2
	cnt+=1
print("Yes" if cnt<=k else "No")

Solution (Python):
r, g, b = map(int, input().split())
k = int(input())
count = 0
while g <= r:
    g *= 2
    count += 1
while b <= g:
    b *= 2
    count += 1
if count <= k:
    print("Yes")
else:
    print("No")

Solution (Python):
a,b,c = map(int, input().split())
k = int(input())

for _ in range(k):
    if c <= b or c <= a:
        c*=2
    elif b <= a:
        b*=2
        
    if a < b and b < c:
        print('Yes')
        break
else:
    print('No')

Solution (Python):
import sys
input = sys.stdin.readline


def readstr():
    return input().strip()


def readint():
    return int(input())


def readnums():
    return map(int, input().split())


def readstrs():
    return input().split()


def main():
    A, B, C = readnums()
    K = readint()
    while K:
        if A >= B:
            B *= 2
            K -= 1
        elif B >= C:
            C *= 2
            K -= 1
        else:
            break

    if A < B < C:
        print('Yes')
    else:
        print('No')


if __name__ == "__main__":
    main()