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.



Sample input:
7 2 5
3


Sample output:
Yes

Submission status: Wrong Answer

Solution code:
import math
A,B,C=(int(x) for x in input().split())
k=int(input())
d=2**k
e=math.ceil(A/B)
f=math.ceil(B/C)
y=math.ceil(A/C)
if y>=f:
    z=y
else:
    z=f

g=0
if e<= 3:
    g+=2
elif e<=2:
    g+=1

if z<= 4:
    g+=2
elif z<=2:
    g+=1
if A==B==C:
    g+=3
elif A==B:
    g+=1
elif A==C:
    g+=1
elif B==C:
    g+=1
if g>k:
    print('No')
else:
    print('Yes')

Submission status: Wrong Answer

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

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

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

Submission status: Wrong Answer

Solution code:
a, b, c = map(int,input().split())
k = int(input())
count = -1

if a >= b:
    for i in range(k):
        b = 2*b
        if a < b:
            count = i
            break
if b >= c:
    for j in range(count+1, k):
        c = 2*c
        if b < c:
            break
if a < b and b < c:
        print("Yes")
else:
    print("No")
print(a, b, c)

Submission status: Wrong Answer

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

Submission status: Wrong Answer

Solution code:
red, green, blue = map(int, input().split())
k = int(input())

ans_list = []
def doble_calc(value, num):
    if num == 1:
        return value
    elif num == 2:
        return value*2
    elif num == 3:
        return value*2*2
    elif num == 4:
        return value*2*2*2
    elif num == 5:
        return value*2*2*2*2
    elif num == 6:
        return value*2*2*2*2*2
    elif num == 7:
        return value*2*2*2*2*2*2
    
for i in range(1, k+1):
    for j in range(1, k+1):
        for l in range(1, k+1):
            if i + j + l == 7:
                ans_list.append([doble_calc(red, i), doble_calc(green, j), doble_calc(blue, l)])
            
for i in ans_list:
    if i[0] < i[1] < i[2]:
        print('Yes')
        break
    else:
        print('No')
        break

Submission status: Wrong Answer

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


def combinations(k):
    result = []
    for a in range(k + 1):
        for b in range(k + 1):
            for c in range(k + 1):
                if a + b + c == k:
                    result.append([a, b, c])

    return result


for l in combinations(K):
    if A * 2 * l[0] < B * 2 * l[1] < C * 2 * l[2]:
        print('Yes')
        break

print('No')

Submission status: Wrong Answer

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

a = int(a)
b = int(b)
c = int(c)
l = []

if k == 1:
    if a < 2*b < c or a < b < 2*c:
        l.append('Yes')
    else:
        l.append('No')
elif a < b*(2**k) < c or a < b < c*(2**k):
    l.append('Yes')
else:
    for i in range(1, k):
        b = b*(2**i)
        c = c*(2**(k-i))
        if c > b > a:
            l.append('Yes')
            break
        else:
            l.append('No')

d = len(l)
print(l[d-1])

Submission status: Wrong Answer

Solution code:
X = list(map(int,input().split()))
A = X[0]
B = X[1]
C = X[2]
K = int(input())
cnt = 0
if A > B:
  for i in range(K):
   B = B*2
   cnt = cnt + 1
   if A < B:
    break
print(B)
if B > C:
  for j in range(K):
   C = C*2
   cnt = cnt + 1
   if B < C:
    break
print(C)
print(cnt)
if cnt <= K:
  print('Yes')
else:
  print('No')

Submission status: Wrong Answer

Solution code:
import math
A,B,C = map(int, input().split())
K = int(input())
if A > B:
  K1 = math.ceil(math.log(A/B,2))
  B = B * (2 ** K1)
elif A == B:
  B = B * 2
  K1 = 1
else:
  K1 = 0
print(B)
if B > C:
  K2 = math.ceil(math.log(B/C,2))
elif B == C:
  K2= 1
else:
  K2= 0

if K1 + K2 <= K:
  print('Yes')
else:
  print('No')

Submission status: Wrong Answer

Solution code:
card = list(map(int, input().split()))
k = int(input())

for i in range(k):
    if card[0] > card[1]:
        card[1] *= 2
    elif card[1] > card[2]:
        card[2] *= 2
    else:
        card[2] *= 2

print("Yes") if card[0] < card[1] < card[2] else print("No")

Submission status: Wrong Answer

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

def yes_no(A, B, C, K):
    for i in range(0, K + 1):
        for j in range(0, K + 1 - i):
            if K - i - j != 0 and i != 0 and j != 0:
                if C * 2 * (K - i - j) > B * 2 * i and B * 2 * i > A * 2 * j:
                    return "Yes"
                    break
            elif K - i != 0 and i != 0 and j == 0:
                if (C * 2 * (K - i) > B * 2 * i and B * 2 * i > A) or\
                   (C * 2 * (K - i) > B and B > A * 2 * i):
                    return "Yes"
            elif K - i - j == K:
                if C * 2 * K > B and B > A:
                    return "Yes"
            elif K - i - j == 0 and i != 0 and j != 0:
                if C > B * 2 * i and B * 2 * i > A * 2 * j:
                    return "Yes"
            elif K - i == 0 :
                if (C > B * 2 * i and B * 2 * i > A) or\
                   (C > B and B > A * 2 * i):
                    return "Yes"

def main():
    ans = yes_no(A, B, C, K)
    if ans == None:
        print("No")
    else:
        print("Yes")

if __name__ == "__main__":
    main()

Submission status: Wrong Answer

Solution code:
a,b,c=(int(x) for x in input().split())
k=int(input())

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

Submission status: Wrong Answer

Solution code:
A,B,C=map(int,input().split())
K=int(input())
list=[A,B,C]

for i in range(K):
    mini=min(list)
    for n in range(3):
        if mini==list[n]:
            list[n]=2*list[n]
           
A=list[0]
B=list[1]
C=list[2]

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

Submission status: Wrong Answer

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


def main():
    if a < b < c:
        return print("Yes")

    x = 0
    y = 0
    for i in range(1, 20):
        x += 1
        y += 1
        if b * (2 ** i) > a:
            break

    for i in range(1, 20):
        if c > b * (2 ** x):
            break
        y += 1
        if c * (2 ** i) > b * (2 ** x) > a:
            break

    if k < y:
        return print("No")

    if c * (2 ** y - 1) - x > b * (2 ** x) > a:
        return print("Yes")

    print("No")


if __name__ == "__main__":
    main()

Submission status: Wrong Answer

Solution code:
import math
A,B,C=(int(x) for x in input().split())
k=int(input())
d=2**k
e=math.ceil(A/B)
f=math.ceil(B/C)
y=math.ceil(A/C)
if y>=f:
    z=y
else:
    z=f

g=0
if e<= 3:
    g+=2
elif e<=2:
    g+=1

if z<= 4:
    g+=2
elif z<=2:
    g+=1
if A==B==C:
    g+=3
elif A==B:
    g+=1
elif A==C:
    g+=1
elif B==C:
    g+=1
if g>=k:
    print('No')
else:
    print('Yes')

Submission status: Wrong Answer

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

Submission status: Wrong Answer

Solution code:
"""
b > g > r

"""

r, g, b = list(map(int, input().split()))
k = int(input())
flag = False
for i in range(k):
    if r < g < b:
        b *= 2
    elif max(r, g, b) == g and (b > r or r > b):
        b *= 2
    elif max(r, g, b) == b and b > 2 * g and (r > g or g > r):
        g *= 2
    elif max(r, g, b) == r and b > g:
        b *= 2
    elif max(r, g, b) == r and g > b:
        b *= 2
if r < g < b:
    flag = True
print("Yes") if flag else print("No")

Submission status: Wrong Answer

Solution code:
a,b,c=map(int,input().split())
k=int(input())
re=0
re1=0
for i in range (k):
    re=re+b*2
    if (re > a ):
        re1 = re1 + c*2
        if (re1 > b):
            print("Yes")
            quit()
        else:
            print("NO")
            quit()

Submission status: Wrong Answer

Solution code:
a, b, c = map(int,input().split())
k = int(input())
count = -1

if a > b:
    for i in range(k):
        b = 2*b
        if a < b:
            count = i
            break
if b > c:
    for j in range(count+1, k):
        c = 2*c
        if b < c:
            break
if a < b and b < c:
        print("Yes")
else:
    print("No")

Submission status: Wrong Answer

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

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

BOX = [A, B, C]
 
1 <= A,B,C <= 7
#1 <= K <= 7

(random.choice(BOX)*2)*7


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

Submission status: Wrong Answer

Solution code:
A, B, C = map(int, input().split(" "))
N = int(input())
newA, newB, newC = A, B, C
n = 0
actions = []
cou = 0
for a in range(N):
    for b in range(N):
        for c in range(N):
            if newA <= newB:
                if newB <= newC:
                    n = 1
                    actions.append([newA, newB, newC])
                else:
                    newC *= 2
                    actions.append([newA, newB, newC])
            else:
                actions.append([newA, newB, newC])
                newC *= 2
                
        newB *= 2
        newC = C
    newA *= 2
    newC = C
    newB = B
if n == 1:
    print("Yes")
if n == 0:
    print("No")

Submission status: Wrong Answer

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

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


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

Submission status: Wrong Answer

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


def main():
    if a < b < c:
        return print("Yes")

    x = 0
    y = 0
    for i in range(1, 20):
        x += 1
        y += 1
        if b * (2 ** i) > a:
            break

    for i in range(1, 20):
        y += 1
        if c * (2 ** i) > b * (2 ** x) > a:
            break

    if k < y:
        return print("No")

    if c * (2 ** y - 1) - x > b * (2 ** x) > a:
        return print("Yes")

    print("No")


if __name__ == "__main__":
    main()

Submission status: Wrong Answer

Solution code:
a, b, c = map(int,input().split())
k = int(input())
count = -1

if a > b:
    for i in range(k):
        b = 2*b
        if a < b:
            count = i
            break
if b > c:
    for j in range(count+1, k):
        c = 2*c
        if b < c:
            break
if a < b and b < c:
        print("Yes")
else:
    print("No")
print(a, b, c)

Submission status: Wrong Answer

Solution code:
A,B,C = map(int,input().split())
K = int(input())
sum = 0
sum1 = 0
sum2 = 0
for i in range(K):
  if (C):
    sum2+=C*2
  elif(B):
    sum1+=B*2
  elif(A):
    sum+=A*2
if (sum1>sum and sum2>sum1):
  print('Yes')
else:
  print('No')

Submission status: Wrong Answer

Solution code:
a,b,c=map(int,input().split())
k=int(input())
for i in range(k):
    if a>b:
        b=b*2
        print(a,b,c)
    else:
        if b>c:
            c=c*2
            print(a,b,c)
        else:
            break

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

Submission status: Wrong Answer

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

ans=0
m2=a
if m2>b:
    for i in range(1,4):
        b=b*2
        ans+=1
        if b>m2:
            break
m=max(a,b)
if m>=c:
    for i in range(1,4):
        c=c*2
        ans += 1
        if c>m:
            break
if ans<=k:
    print("Yes")
else:
    print("No")

Submission status: Wrong Answer

Solution code:
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)
if a < b and b<c and k>=0:
  print("Yes")
else:
  print("No")

Submission status: Wrong Answer

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

if K==0:
    if B > A and C > B:
        flag=1
        print('Yes')
    else:
        pass
elif K>0:
    if B<=A:
        for k in range(K):
            if B*(k+1)*2>A:
                Bnew=B*(k+1)*2
                newK = K - k - 1
                for newk in range(newK):
                    if C * (newk + 1) * 2 > Bnew:
                        print('Yes')
                        flag=1
                        break
                break
    else:
        for k in range(K):
            if C * (k + 1) * 2 > B:
                print('Yes')
                flag = 1

if flag == 0:
    print('No')

Submission status: Wrong Answer

Solution code:
A, B, C = map(int, input().split(" "))
N = int(input())
newA, newB, newC = A, B, C
n = 0
actions = []
cou = 0
for a in range(N):
    for b in range(N):
        for c in range(N):
            if newA < newB:
                if newB < newC:
                    n = 1
                    actions.append([newA, newB, newC])
                else:
                    newC *= 2
                    actions.append([newA, newB, newC])
            else:
                actions.append([newA, newB, newC])
                newC *= 2
                
        newB *= 2
        newC = C
    newA *= 2
    newC = C
    newB = B
if n == 1:
    print("Yes")
if n == 0:
    print("No")

Submission status: Wrong Answer

Solution code:
[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):
        if i > 0 :
            R = A*2*i
        else:
            R = A
        if j > 0 :
            G = B*2*j
        else :
            G = B
        if (K-i-j)>0 :           
            Bl = C*2*(K-i-j)
        else:
            Bl = C
        if G > R and Bl > G :
            ans = 'Yes'
            break

print(ans)

Submission status: Wrong Answer

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

a = int(a)
b = int(b)
c = int(c)
l = []

if k == 1:
    if a < 2*b < c or a < b < 2*c:
        l.append('Yes')
    else:
        l.append('No')
if a < b*(2**k) < c or a < b < c*(2**k):
    l.append('Yes')
else:
    for i in range(1, k):
        b = b*(2**i)
        c = c*(2**(k-i))
        if c > b > a:
            l.append('Yes')
            break
        else:
            l.append('No')

d = len(l)
print(l[d-1])

Submission status: Wrong Answer

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

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

Submission status: Wrong Answer

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

Submission status: Wrong Answer

Solution code:
a,b,c = map(int,input().split())
k = int(input())
res = True
for i in range(k):
    if b > a:
        if c > b:
            break
        else:
            c *= 2
    elif b < a:
        b *= 2
res = a < b < c
if res:
    print("Yes")
else:
    print("No")

Submission status: Wrong Answer

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

# A < B < C


def main():
    if a < b < c:
        return print("Yes")

    x = 0
    y = 0
    for i in range(1, 20):
        x += 1
        y += 1
        if b * 2 ** i > a:
            break

    for i in range(1, 20):
        y += 1
        if c * 2 ** i > b * 2 ** x > a:
            break

    if c * 2 ** y - x > b * 2 ** x > a:
        return print("Yes")

    print("No")


if __name__ == "__main__":
    main()

Submission status: Wrong Answer

Solution code:
A, B, C = (int(x) for x in 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')

Submission status: Wrong Answer

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

Submission status: Wrong Answer

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

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

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

Submission status: Wrong Answer

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

K = int(input())

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

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

Submission status: Wrong Answer

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

if K==0:
    if B > A and C > B:
        print('Yes')
    else:
        print('No')
else:
    if B<=A:
        for k in range(K):
            if B*(k+1)*2>A:
                Bnew=B*(k+1)*2
                newK = K - k - 1
                for newk in range(newK):
                    if C * (newk + 1) * 2 > Bnew:
                        print('Yes')
                        flag=1
                        break
                break
    else:
        for k in range(K):
            if C * (k + 1) * 2 > B:
                print('Yes')
                flag = 1


if flag == 0:
    print('No')

Submission status: Wrong Answer

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

Submission status: Wrong Answer

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

# A < B < C


def main():
    if a < b < c:
        return print("Yes")

    x = 0
    y = 0
    for i in range(1, 20):
        x += 1
        y += 1
        if b * 2 ** i > a:
            break

    for i in range(1, 20):
        if c * 2 ** i > b * 2 ** x > a:
            break
        y += 1

    if k < y:
        return print("No")

    if c * 2 ** y - x > b * 2 ** x > a:
        return print("Yes")

    print("No")


if __name__ == "__main__":
    main()

Submission status: Wrong Answer

Solution code:
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")

Submission status: Wrong Answer

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

for i in range(0,K+1):
    for j in range(0,K+1-i):
        for k in range(0,K+1-i-j):
            #print('{},{},{}'.format(i,j,k))
            if(A*i*2+A < B*j*2+B and B*j*2+B < C*k*2+C):
                if(i==j==k==0):
                    break
                print('Yes')
                exit()

print('No')

Submission status: Wrong Answer

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

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

Submission status: Wrong Answer

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

ans = False

for _ in range(k):

    if c>b>a:
        ans = True
        break

    if a > c:
        c *= 2
        continue

    if c < b:
        if b < a:
            b *= 2
        else:
            c *= 2
    else:
        b *= 2

if c>b>a:
    ans = True

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

Submission status: Wrong Answer

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

K = int(input())

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

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

Submission status: Wrong Answer

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

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

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

Submission status: Wrong Answer

Solution code:
A,B,C = map(int, input().split())
K = int(input())
new_A = (A*2)**K
new_B = (B*2)**K
new_C = (C*2)**K

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

Submission status: Wrong Answer

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

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

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

Submission status: Wrong Answer

Solution code:
numbers = [int(s) for s in input().split()] #0:赤, 1:緑, 2:青
K = int(input())
for i in range(K):
    if(numbers[2] < numbers[0]):
        numbers[2] *= 2
    elif(numbers[2] < numbers[1]):
        numbers[1] *= 2
    elif(numbers[1] < numbers[0]):
        numbers[2] *= 2
    else:
        break
if(numbers[1] > numbers[0] and numbers[2] > numbers[1]):
    print("Yes")
else:
    print("No")

Submission status: Wrong Answer

Solution code:
A, B, C = map(int, input().split(" "))
N = int(input())
newA, newB, newC = A, B, C
n = 0
cou = 0
for a in range(N):
    for b in range(N):
        for c in range(N):
            if newA < newB:
                if newB < newC:
                    n = 1
                    cou += 1
            else:
                newC *= 2
                cou += 1
                
        newB *= 2
        newC = C
    newA *= 2
    newC = C
    newB = B
if n == 1:
    print("Yes")
if n == 0:
    print("No")

Submission status: Wrong Answer

Solution code:
R, G, B = map(int, input().split())
K = int(input())

while K > 0:
    
    if G > R:
        R *= 2
        K -= 1
    elif B > G:
        G *= 2
        K -= 1
    else:
        break
        
if K != 0:
    print("No")
else:
    print("Yes")

Submission status: Wrong Answer

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

Submission status: Wrong Answer

Solution code:
#!/usr/bin/env python3
def main():
    R, G, B = map(int, input().split())
    K = int(input())

    if B > G > R:
        print("Yes")
        exit()
    C = 0
    for i in range(1,K,1):
        if G * 2 * i > R:
            C = i
    if C > 0:
        if B * 2 * (K-C) > G * 2 * C:
            print("Yes")
            exit()

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

Submission status: Wrong Answer

Solution code:
ins=input()
ins=[int(r) for r in ins.split()]
A,B,C=ins
K=input()
K=int(K)

ans='No'

for i in range(K):
  for j in range(K-i+1):
    red=A
    green=B
    blue=C
    print(green*(2**i),blue*(2**j))
    if red<green*(2**i) and green*(2**i) <blue*(2**j):
      ans='Yes'
      break
    elif red<green*(2**j) and green*(2**j) < blue*(2**i):
      ans='Yes'
      break


print(ans)

Submission status: Wrong Answer

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

Submission status: Wrong Answer

Solution code:
numbers = [int(s) for s in input().split()] #0:赤, 1:緑, 2:青
K = int(input())
for i in range(K):
    if(numbers[2] < numbers[0]):
        numbers[2] *= 2
        
    elif(numbers[1] < numbers[0]):
        numbers[1] *= 2
        
    elif(numbers[2] < numbers[1]):
        numbers[2] *= 2
        
    else:
        break
if(numbers[1] > numbers[0] and numbers[2] > numbers[1]):
    print("Yes")
else:
    print("No")

Submission status: Wrong Answer

Solution code:
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')

Submission status: Wrong Answer

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

K = int(input())

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

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

Submission status: Wrong Answer

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

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

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

Submission status: Wrong Answer

Solution code:
a, b, c = map(int, input().split())#赤midoriao
k = int(input())
#赤＜緑＜青
if a < b and b<c:
  print("Yes")
else:
  while a>=b:
    b = b*2
    k-=1
  #print(b)
  while b>=c or k>0:
    c = c*2
    k-=1
if a < b and b<c and k>=0:
  print("Yes")
else:
  print("No")

Submission status: Wrong Answer

Solution code:
A,B,C = map(int,input().split())
K = int(input())
sum = 0
sum1 = 0
sum2 = 0
for i in range(K):
  if (C):
    sum+=C*2
  elif(B):
    sum1+=B*2
  elif(A):
    sum2+=A*2
if (sum1>A and sum>sum1):
  print('Yes')
else:
  print('No')

Submission status: Wrong Answer

Solution code:
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 and b<c:
    print('Yes')
else:
    print('No')

Submission status: Wrong Answer

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

for i in range(0,K+1):
    for j in range(0,K+1-i):
        for k in range(0,K+1-i-j):
            #print('{},{},{}'.format(i,j,k))
            if(A*i*2+A < B*j*2+B and B*j*2+B < C*k*2+C):
                print('Yes')
                exit()

print('No')

Submission status: Wrong Answer

Solution code:
num = input("").split(" ")
num = [int(i) for i in num]
K = int(input(""))

for i in range(0, K):

    if num[1] > num[2]:
        num[2] = num[2] * 2

    elif num[0] > num[1]:
        num[1] = num[1] * 2

    elif num[0] > num[2]:
        num[2] = num[2] * 2

    else:
        num[2] = num[2] * 2

if num[2] > num[1] > num[0]:
    print("Yes")
else:
    print("No")

Submission status: Wrong Answer

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

for i in range(0,k+1):
  b1=b*2*i
  g2=g*2*(k-i)
  if r<g2 and g2<b1:
    print("Yes")
    exit()
    
for i in range(0,k+1):
  b1=b*2*(k-i)
  g2=g*2*i
  if r<g2 and g2<b1:
    print("Yes")
    exit()
    
print("No")

Submission status: Wrong Answer

Solution code:
a, b, c = map(int, input().split())
K = int(input())

f = 0
if a < b < c:
    f = 1
elif a < c < b:
    if c * 2 ** K > b:
        f = 1
elif b < a < c:
    for _ in range(K):
        b *= 2
        if a < b < c:
            f = 1
            break
elif c < a < b:
    if c * 2 ** K > b:
        f = 1
elif b < c < a:
    k = 1
    for x in range(1, K + 1):
        c *= 2
        if c > a:
            k = x
            break

    K -= k
    if K > 0:
        for _ in range(1, K + 1):
            b *= 2
            if a < b < c:
                f = 1
                break
elif c < b < a:
    k = 1
    for x in range(1, K + 1):
        b *= 2
        if b > a:
            k = x
            break

    K -= k
    if K > 0:
        for _ in range(1, K + 1):
            c *= 2
            if a < b < c:
                f = 1
                break
else:
    if K >= 3:
        f = 1

print(['No', 'Yes'][f])

Submission status: Wrong Answer

Solution code:
a, b, c = map(int, input().split())#赤midoriao
k = int(input())
#赤＜緑＜青
if a < b and b<c:
  print("Yes")
else:
  while a>=b:
    b = b*2
    k-=1
  #print(b)
  while b>=c or k>0:
    c = c*2
    k-=1
if a < b and b<c:
  print("Yes")
else:
  print("No")

Submission status: Wrong Answer

Solution code:
A, B, C = map(int, input().split(" "))
N = int(input())
newA, newB, newC = A, B, C
n = 0
cou = 0
for a in range(N):
    for b in range(N):
        for c in range(N):
            if newA < newB and newB < newC:
                n = 1
                cou += 1
            else:
                newC *= 2
                cou += 1
                
        newB *= 2
        newC = C
    newA *= 2
    newC = C
    newB = B
if n == 1:
    print("Yes")
if n == 0:
    print("No")

Submission status: Wrong Answer

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

# A < B < C


def main():
    if a < b < c:
        print("Yes")
        return

    x = 0
    y = 0
    for i in range(1, 20):
        x += 1
        y += 1
        if b * 2 ** i > a:
            break

    for i in range(1, 20):
        y += 1
        if c * 2 ** i > b * 2 ** x > a:
            break

    if k < y:
        return print("No")

    if c * 2 ** y - x > b * 2 ** x > a:
        return print("Yes")

    print("No")


if __name__ == "__main__":
    main()

Submission status: Wrong Answer

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

Submission status: Wrong Answer

Solution code:
R,G,B = map(int,input().split())
K = int(input())

if R < G < B:
  print("Yes")
  
for i in range(K):
  if R > G:
    G*=2
    if R < G < B:
      print("Yes")
  elif G > B:
    B*=2
    if R < G < B:
      print("Yes")
  elif R > B:
    B*=2
    if R < G < B:
      print("Yes")
  else:
    pass
  
if R < G < B:
  pass
else:
  print("No")