peterverebics/CodeNet_Python_118 huggingface dataset:
import math
a,b,c = [int(x) for x in input().split()]
k = int(input())
a1,b1,c1 = math.log2(a),math.log2(b),math.log2(c)
k1,k2 = 0,0
# print(a1,b1,c1)
if b1<=a1:
    k1 = math.floor(a1-b1+1)
    b1 = b1+k1
if c1<=b1:
    k2 = math.floor(b1-c1+1)
if k1+k2<=k:
    print("Yes")
else:
    print("No")
a, b, c = [int(x) for x in input().strip().split()]
k = int(input())

while (b<=a or c<=b) and k:
    
    if b<=a:
        b = b*2
    else:
        c = c*2
    
    k-=1

if a<b<c:
    print('Yes')
else:
    print('No')
A,B,C=map(int,input().split())
K=int(input())
M=K
for i in range(K):
    if A>=B:
        B=B*2
        M=K-(i+1)
    if A<B:
        break
C=C*(2**M)
if C>B and A<B:
    print('Yes')
else:
    print('No')
a,b,c=map(int,input().split())
k=int(input())
while k>0:
  if not b>a:
    b*=2
    k-=1
  elif not c>b:
    c*=2
    k-=1
  else:
    break

if c>b and b>a:
  print("Yes")
else:
  print("No")
a, b, c = map(int, input().split())
k = int(input())

count = 0
while a >= b:
    b *= 2
    count += 1
    # print("b", b)

while b >= c:
    c *= 2
    count += 1
    # print("c", c)

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

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

if a<b and b<c:
  print('Yes')
else:
  print('No')
a, b, c = map(int, input().split())#赤midoriao
k = int(input())
#赤＜緑＜青
if (a < b) and (b<c):
  print("Yes")
else:
  while (a>=b) and (k>0):
    b = b*2
    k-=1
  #print(b)
  #print(k)
  while (b>=c) and (k>0):
    c = c*2
    k-=1
  #print(c)
  #print(k)
#print(a,b,c,k)
  if (a < b) and (b<c) and (k>=0):
    print("Yes")
  else:
    print("No")
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')
a, b, c = map(int, input().split())
k = int(input())

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

if (c > b and b > a):
    print("Yes")
else:
    print("No")
from sys import *
a,b,c = map(int,stdin.readline().split())
k = int(stdin.readline())
while b <= a:
    b = b*2
    k -= 1
while c <= b:
    c = c*2
    k -= 1
if k < 0:
    print("No")
else:
    print("Yes")
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')
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')
#b

# B > A
# C > B

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

k = 0
while B<=A:
    B*=2
    k += 1

while C<=B:
    C*=2
    k+=1
    
if k<=K:
    print("Yes")
else:
    print("No")
def main():
    a, b, c = map(int, input().split())
    k = int(input())
    while b <= a:
        b *= 2
        k -= 1
        if k < 0:
            print('No')
            exit()
    while c <= b:
        c *= 2
        k -= 1
        if k < 0:
            print('No')
            exit()
    print('Yes')
    
if __name__ == '__main__':
    main()
import sys

def I(): return int(sys.stdin.readline().rstrip())
def LI(): return list(map(int,sys.stdin.readline().rstrip().split()))
def S(): return sys.stdin.readline().rstrip()
def LS(): return list(sys.stdin.readline().rstrip().split())

A,B,C = LI()
K = I()



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

if A < B < C:
    print('Yes')
else:
    print('No')
a,b,c = map(int, raw_input().split())
k = int(raw_input())
# greedily

while( a >= b):
	b*= 2
	k -=1
while( b >= c):
	c*= 2
	k -=1

print 'Yes' if k >= 0 else 'No'
a,b,c=map(int,input().split())
k=int(input())
for _ in range(k):
  if b<=a:
    b*=2
    continue
  if c<=b:
    c*=2
    continue
if a<b and b<c:
  print('Yes')
else:
  print('No')
a,b,c = map(int,input().split())
k = int(input())
for i in range(k):
    if b <= a:
        b*=2
        continue
    if c <= b:
        c*=2
if a < b and b < c:
    print("Yes")
else:
    print("No")
i = list(map(int, input().split()))
limit = int(input())
k = 0
while not i[0] < i[1] < i[2]:
    if i[2] <= i[1]:
        i[2] *= 2
        k += 1
    if k == limit:
        break
    if i[1] <= i[0]:
        i[1] *= 2
        k += 1
    if k == limit:
        break
if k <= limit and i[0] < i[1] < i[2]:
    print("Yes")
else:
    print("No")
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
  elif R > B:
    B*=2
  elif R == G == B:
    B *= 2
  elif R == G:
    G *= 2
  elif G == B:
    B *= 2
  else:
    pass
if R < G < B:
  print("Yes")
else:
  print("No")
a,b,c = map(int,input().split())
k=int(input())

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

if c > b and b > a and c >a:
    print("Yes")
else:
    print("No")
a,b,c = list(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 c > b and b > a:
    print("Yes")
else:
    print("No")
A,B,C = map(int, input().split())
K = int(input())

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

if A < B and B < C:
  print("Yes")
else:
  print("No")
a, b, c = map(int, input().split())
k = int(input())
ans = 0
while b <= a:
    b *= 2
    ans += 1
while c <= b:
    c *= 2
    ans += 1
print('Yes' if ans <= k else 'No')
(A, B, C, ) = [int(n) for n in input().split()]
(K, ) = [int(n) for n in input().split()]

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

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

if K >= 0:
    print('Yes')
else:
    print('No')
a,b,c = list(map(int,input().split()))
k = int(input())

cnt = 0

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

while not b < c:
  c*=2
  cnt+=1

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

while b >= c:
    c = c*2
    m += 1
    if b < c:
        break
    
if k >= m:
    print("Yes")
else:
    print("No")
#標準入力
A,B,C = map(int,input().split())
K=int(input())

cnt = 0

while A >= B:
    B=B*2
    cnt+=1
    if A < B:
        break

while B >= C:
    C=C*2
    cnt+=1
    if B < C:
        break

ans = 'Yes' if cnt <= K else 'No'

print(ans)
l = list(map(int, input().split()))
K = int(input())

def check(nums):
    if nums[0] < nums[1]:
        if nums[1] < nums[2]:
            print('Yes')
            exit(0)

check(l)
for i in range(K):
    if l[0] >= l[1]:
        l[1] *= 2
        check(l)
        continue
    elif l[1] >= l[2]:
        l[2] *= 2
        check(l)
        continue

print('No')

exit(0)
import sys
from collections import defaultdict, Counter, namedtuple, deque
import itertools
import functools
import bisect
import heapq
import math
import copy
# from fractions import gcd

MOD = 10 ** 9 + 7
# MOD = 998244353
# sys.setrecursionlimit(10**8)

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

if count <= k:
    print("Yes")
else:
    print("No")
import math
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 a<b and b<c:
    print("Yes")
else:
    print("No")
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 k >= 0:
    print("Yes")
else:
    print("No")
[r,g,b]=list(map(int,input().split()))
#b>g>r
k=int(input())
m=k
n=0
while m>=0:
  tg=pow(2,m)*g
  tb=pow(2,n)*b
  if tg>r and tb>tg:
    print("Yes")
    exit(0)
  m-=1
  n+=1
print("No")
a, b, c = map(int, input().split())
k = int(input())

for i in range(k):
    if a >= b:
        b = b * 2
    else:
        if b >= c:
            c = c * 2
        else:
            break
if a < b < c:
    print("Yes")
else:
    print("No")
A,B,C=map(int,input().split())
K=int(input())

nax=2**K

if A<B and B<C:
    print('Yes')
else:
    count=0
    while B<=A:
        B=B*2
        count+=1
    C=C*(2**(K-count))
    if A<B and B<C:
        print('Yes')
    else:
        print('No')
import sys
 
def main():
  a,b,c = map(lambda x: int(x), input().split())
  k = int(input())
 
  for _ in range(k):
      if b <= a:
          b = 2 * b
          continue
      if c <= b:
          c = 2 * c
          continue
      print('Yes')
      return
 
  if (a < b) & (b < c):
      print('Yes')
      return
  print('No')
 
if __name__ == '__main__':
    main()
A,B,C=map(int,input().split())
K=int(input())
D=[]
for i in range(K):
    for j in range(K-i):
        if A*(2**i)<B*(2**j) and B*(2**j)<C*(2**(K-i-j)):
            D.append('Yes')
        else:
            D.append('No')
if ('Yes' in D)==True:
    print('Yes')
else:
    print('No')
a,b,c = map(int, input().split())
k = int(input())

for i in range(k+1):
    if b>a:
        if c>b:
            print('Yes')
            break
        else:
            c *= 2
    else:
        b *= 2
else:
    print('No')
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 k>=0:
    print('Yes')
else:
    print('No')
A,B,C = map(int,input().split())
K = int(input())

i = 0
while B <= A:
  B *= 2
  i += 1
  
while C <= B:
  C *= 2
  i += 1

print('Yes' if i <= K else 'No')
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')
a, b, c = map(int, input().split())
k = int(input())

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

    if c > b > a:
        print('Yes')
        quit()

print('No')
import sys
input = sys.stdin.readline

ABC = list(map(int, input().split()))
K = int(input())

for i in range(K+1):
    if ABC[0] < ABC[1] and ABC[1] < ABC[2]:
        print("Yes")
        break
    elif ABC[0] >= ABC[2]:
        ABC[2] = 2 * ABC[2]
    elif ABC[1] >= ABC[2]:
        ABC[2] = 2 * ABC[2]
    elif ABC[0] >= ABC[1]:
        ABC[1] = 2 * ABC[1]
        
else:
  print("No")
a, b, c = map(int, input().split())
k = int(input())

if a >= b:
    while a >= b:
        if k == 0:
            print("No")
            exit()
        b *= 2
        k -= 1

if b >= c:
    while b >= c:
        if k == 0:
            print("No")
            exit()
        c *= 2
        k -= 1

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


def input():
    return sys.stdin.readline().rstrip()


def main():
    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
    if count >K:
        print("No")
    else:
        print("Yes")






if __name__ == "__main__":
    main()
A,B,C=map(int,input().split())
K=int(input())

for i in range(K+1) :
    for j in range(K+1-i) :
        a=A*(2**i)
        b=B*(2**j)
        c=C*(2**(K-i-j))
        if a<b<c :
            print("Yes")
            exit()

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

t = 0
s = 0
while a[1] <= a[0]:
    a[1] = a[1] * 2
    t = t + 1
while a[2] <= a[1]:
    a[2] = a[2] * 2
    s = s + 1

if t+s <=b:
    print("Yes")
else:
    print("No")
import sys

A,B,C=map(int,input().split())
K=int(input())
for i in range(K+1):
  if(A<B and B<C):
    print("Yes")
    sys.exit()
  elif(A>=B):
    B*=2
  elif(B>=C):
    C*=2
print("No")
import sys
from math import sqrt, gcd, ceil, log
from bisect import bisect, bisect_left
from collections import defaultdict, Counter, deque
from heapq import heapify, heappush, heappop
inp = sys.stdin.readline
read = lambda: list(map(int, inp().strip().split()))

def main():
	a, b, c = read(); k = int(input())
	# k -= 1
	while b <= a:
		b *= 2
		k -= 1
	while c <= b:
		c *= 2; k -= 1
	print("YNeos"[k < 0::2])






if __name__ == "__main__":
	main()
import sys
import math
def get_array(): return list(map(int, sys.stdin.readline().strip().split()))
def get_ints(): return map(int, sys.stdin.readline().strip().split())
def input(): return sys.stdin.readline().strip()
a,b,c=get_ints()
k=int(input())
flag=0
for i in range(k+1):
    if b>a and c>b:
        flag=1
        break
    else:
        if b<=a:
            b=b*2
        else:
            c=c*2
if flag==1:
    print("Yes")
else:
    print("No")
a, b, c = map(int, input().split())
k = int(input())

m = 0
while a >= b:
    m += 1
    b *= 2
while b >= c:
    m += 1
    c *= 2

if m <= k:
    print('Yes')
else:
    print('No')
A,B,C = map(int,input().split())
K = int(input())

for i in range(K):
  if B <= A:
    B *= 2
    continue
  if C <= B:
    C *= 2
    continue
    
if A < B < C:
  print("Yes")
else:
  print("No")
A, B, C = list(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')
# coding: utf-8
# Your code here!
import sys
read = sys.stdin.read
readline = sys.stdin.readline

a,b,c,k = map(int, read().split())


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

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

if v <= k:
    print("Yes")
else:
    print("No")
a,b,c = map(int,input().split())
K = int(input())
j = K
for i in range(K):
    if b-a>0:
        break
    b *=2
    if b-a>0:
        j = K-(i+1)
        break
if b-a<=0:
    print('No')
    exit()
if j==0:
    if c-b >0:
        print('Yes')
        exit()
if c*(2**j)-b >0:
    print('Yes')
else:
    print('No')
a,b,c=map(int,input().split())
k=int(input())

while b<=a and k>=1:
  b*=2
  k-=1
while c<=b and k>=1:
  c*=2
  k-=1
if c>b>a:
  print("Yes")
else:
  print("No")
A,B,C = map(int,input().split())

K = int(input())

for x in range(K):
  if A<B*(2**x) and B*(2**x)<C*(2**(K-x)):
    print('Yes');exit()
      
print('No')
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')
A, B, C = map(int, input().split())
K = int(input())

for i in range(K):
    if A < B < C:
        print("Yes")
        exit()
    elif A <= C <= B:
        C *= 2
    elif B <= A <= C:
        B *= 2
    elif B <= C <= A:
        C *= 2
    elif C <= A <= B:
        C *= 2
    elif C <= B <= A:
        C *= 2

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

read = sys.stdin.read
readline = sys.stdin.readline
readlines = sys.stdin.readlines
sys.setrecursionlimit(10 ** 9)
INF = 1 << 60
MOD = 1000000007


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

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

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

    return


if __name__ == '__main__':
    main()
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 < C:
    print('Yes')
else:
    print('No')
a, b, c = list(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 < c:
    print("Yes")
else:    
    print("No")
a,b,c = map(int,input().split())
k=int(input())

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


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

if ans>k:
  print("No")
else:
  print("Yes")
import sys
input=sys.stdin.buffer.readline
import os
from math import*

r,g,b=map(int,input().split())
k=int(input())
while g<=r and k>0:
	g*=2
	k-=1
while b<=g and k>0:
	b*=2
	k-=1
if b>g and g>r:
	print("Yes")
else:
	print("No")
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')
#!/usr/bin/python3
# -*- coding: utf-8 -*-
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")
R, G, B = map(int, input().split())
K = int(input())

ng = True
for ig in range(K):
    ib = K - ig
    if G * (2**ig) > R and B * (2** ib) > G * (2**ig):
        ng = False
        break

if ng:
    print('No')
else:
    print("Yes")
a, b, c = map(int, input().split())
k = int(input())
ans = "No"
for ia in range(k + 1):
    for ib in range(k + 1):
        for ic in range(k + 1):
            if ia + ib + ic > k:
                break
            if (b * 2 ** ib > a * 2 ** ia) and (c * 2 ** ic > b * 2 ** ib):
                ans = "Yes"
print(ans)
a, b, c = map(int, input().split())
k = int(input())

count = 0
flag = 1

while 1:
  if count > k:
    flag = 0
    break
  if b > a:
    break
  b = 2 * b
  count += 1
  

while 1:
  if count > k:
    flag = 0
  if c > b:
    break
  c = 2 * c
  count += 1
  
if flag == 0:
  print("No\n")
else:
  print("Yes\n")
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")
A, B, C = map(lambda x: int(x), input().split(" "))
K = int(input())

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

if A < B < C:
    print("Yes")
else:
    print("No")
A, B, C = map(int,input().split())

K = int(input())

flag = False

for i in range(0, K+1):
    for j in range(0, K+1):
        for k in range(0, K+1):
            x = A * 2**i
            y = B * 2**j
            z = C * 2**k
            # print(x, y, z)

            if x < y < z and i + j + k <= K:
                flag = True


if flag == True:
    print('Yes')
else:
    print('No')
a, b, c = map(int, input().split())
k = int(input())

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

while True:
    if b < c:
        break
    cnt += 1
    c *= 2

if cnt > k:
    print("No")
else:
    print("Yes")
A, B, C = map(int, input().split())
K = int(input())

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

if (B > A) and (C > B):
    print ('Yes')
else:
    print ('No')
A, B, C = map(int, input().split())
K = int(input())
c = 0
while A>=B:
  B *= 2
  c += 1
while B>= C:
  C *= 2
  c += 1
print("Yes" if c<=K else "No")
import sys
input = sys.stdin.readline

def main():
    r,g,b = map(int, input().split())
    k = int(input())
    
    for i in range(k):
        for j in range(k):
            if i+j > k:
                continue
            if r*2**i < g*2**j < b*2**(k-i-j):
                print('Yes')
                return
    print('No')
    
main()
a = list(map(int,input().split()))
b=int(input())
for i in range(b):
  if a[0]>=a[1]:
    a[1]=a[1]*2
  else:
    if a[1]>=a[2]:
      a[2]=a[2]*2
if a[0]<a[1]<a[2]:
  print("Yes")
else:
  print("No")
list=input().split()
num=int(input())
A,B,C=int(list[0]),int(list[1]),int(list[2])

pattern=[[i,num-i] for i in range(num+1)]
temB=B
temC=C
a=0
for pt in pattern:
  B=B*(2**pt[0])
  C=C*(2**pt[1])
  
  
  if A<B<C:
    print('Yes')
    a=1
    break
   
  B=temB
  C=temC

if a!=1:
  print('No')
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")
a, b, c = map(int, input().split())

k = int(input())

ans = 0

while True:
    if b <= a:
        b *= 2
        ans+=1
    elif c <= b:
        c *= 2
        ans += 1
    if a < b and b < c:
        break
if ans > k:
    print('No')
else:
    print('Yes')
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")
import itertools
A,B,C = map(int,input().split())
N = int(input())

for i in range(N):
  for j in range(N):
    k = N-(i+j)
    P = A*pow(2,i)
    Q = B*pow(2,j)
    R = C*pow(2,k)
    #print(A,B,C,C>B)
    if R > Q and Q > P:
      print("Yes")
      exit()
print("No")
a,b,c=map(int,input().split())
k=int(input())
if c>b and b>a:
    print("Yes")
else:
    if b<=a:
        while(b<=a and k>0):
            b=b*2
            k-=1
    if c<=b:
        while(c<=b and k>0):
            c=c*2
            k-=1
    if c>b and b>a:
        print("Yes")
    else:
        print("No")
a, b, c = map(int, input().split())
k = int(input())

cnt = 0
for _ in range(k+1):
    if b <= a:
        b *= 2
        cnt += 1
    else:
        break
        
for _ in range(k+1):
    if c <= b:
        c *= 2
        cnt += 1
    else:
        break
        
        
if cnt > k:
    print("No")
else:
    print("Yes")
a, b, c = map(int, input().split())
k = int(input())

e = 0
while a >= b:
  b *= 2
  e += 1
while b >= c:
  c *= 2
  e += 1
#print(e, k)
if e > k:
  print('No')
else:
  print('Yes')
a, b, c = list(map(int, input().split()))
k = int(input())
for _ in range(k):
  if not a < b:
    b *= 2
  elif not b < c:
    c *= 2
if a < b and b < c:
  print('Yes')
else:
  print('No')
a,b,c = list(map(int,input().split()))
k = int(input())

count = 0

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

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

if count <= k:
    print("Yes")
else:
    print("No")
from math import log2, ceil

a, b, c = map(int, input().split())
k = int(input())
# n >= log2((a+1)/b)
bi = ceil(log2((a+1) / b))
bi = max(bi, 0)
b *= pow(2, bi)
ci = ceil(log2((b+1) / c))
ci = max(ci, 0)
if bi + ci <= k:
    print("Yes")
else:
    print("No")
a,b,c = map(int, input().split())
k = int(input())

for ai in range(k+1):
    for bi in range(k+1):
        for ci in range(k+1):
            if not (ai + bi + ci == k):
                continue
            newA = a * (2 ** ai)
            newB = b * (2 ** bi)
            newC = c * (2 ** ci)

            if newB > newA and newC > newB:
                print('Yes')
                exit()

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

while K:
  if A>=B:
    B*=2
    K-=1
  elif B>=C:
    C*=2
    K-=1
  else:
    break
  
#print(A,B,C)  
if A<B<C:
  print("Yes")
else:
  print("No")
a,b,c=map(int,input().split())
k=int(input())
ans=0
while a>=b:
    b*=2
    ans+=1
while b>=c:
    c*=2
    ans+=1
if ans<=k:
    print("Yes")
else:
    print("No")
a, b, c = map(int, input().split())
k = int(input())

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

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

if a < b < c:
  print("Yes")
else:
  print("No")
import sys
readline = sys.stdin.buffer.readline
def even(n): return 1 if n%2==0 else 0

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

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

if ct <= k:
    print("Yes")
else:
    print("No")
import sys
input=sys.stdin.readline

a,b,c=map(int,input().split())
k=int(input())
for _ in range(k):
    if a>=b:
        b*=2
    else:
        if b>=c:
            c*=2

if a<b and b<c:
    print('Yes')
else:
    print('No')
# Fast IO (only use in integer input)

import os,io
input=io.BytesIO(os.read(0,os.fstat(0).st_size)).readline

a,b,c = map(int,input().split())
k = int(input())
minMagic = 0
while a >= b:
    b *= 2
    minMagic += 1
while b >= c:
    c *= 2
    minMagic += 1
if minMagic <= k:
    print("Yes")
else:
    print("No")
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")
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 print("No")