Problem:


Score : 200 points

Problem Statement

La Confiserie d'ABC sells cakes at 4 dollars each and doughnuts at 7 dollars each.
Determine if there is a way to buy some of them for exactly N dollars. You can buy two or more doughnuts and two or more cakes, and you can also choose to buy zero doughnuts or zero cakes.

Constraints

N is an integer between 1 and 100, inclusive.

Input

Input is given from Standard Input in the following format:

N

Output

If there is a way to buy some cakes and some doughnuts for exactly N dollars, print Yes; otherwise, print No.

Sample Input 1

11

Sample Output 1

Yes

If you buy one cake and one doughnut, the total will be 4 + 7 = 11 dollars.

Sample Input 2

40

Sample Output 2

Yes

If you buy ten cakes, the total will be 4 \times 10 = 40 dollars.

Sample Input 3

3

Sample Output 3

No

The prices of cakes (4 dollars) and doughnuts (7 dollars) are both higher than 3 dollars, so there is no such way.



Sample input:
11


Sample output:
Yes

Submission status: Runtime Error

Solution code:
N = int(input())
for i in range():
	for j in range():
      if 4*i+7*j==N:
        print('YES')
      else:
        print('NO')

Submission status: Runtime Error

Solution code:
n = int(input())
 
for i in range((n//4)+1):
    for j in range((n//7)+1):
        if (i*4) + (j*7) == n:
            print("Yes")
            exit()
print("No"

Submission status: Runtime Error

Solution code:
n = input()
m = (n // 7) * 7
if m == n:
    print("Yes")
elif m - n <= n // 7:
    print("Yes")
else:
     print("No")

Submission status: Runtime Error

Solution code:
n=int(input())
#4
#7
ans=False
if n%7==0:
    ans==True


for i in range(n/7):
    if (n-i*7)%4==0:
        ans=True
        

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

Submission status: Runtime Error

Solution code:
n = int(input())
max_f = int(n / 4)
max_s = int(n / 7)
switch = 0
for i in range(max_s + 1):
    for j in range(max_f + 1):
        if (7 * i + 4 * j) == n:
            switch = 1
if switch == 1:
    print(Yes)
else:
    print(No)

Submission status: Runtime Error

Solution code:
def Cakes_and_Donuts(N):
    CP = 4
    DP = 7
    
    if N <= 3:
        return f"No"
    
    for i in range(26):
        for j in range(15):
            if (CP * i + DP * j) == N:
                return f"Yes"
    
    return f"No"
  
  N = int(input())
  Cakes_and_Donuts(N)

Submission status: Runtime Error

Solution code:
def main(N):
    CP = 4
    DP = 7
    
    if N <= 3:
        return f"No"
    
    for i in range(26):
        for j in range(15):
            if (CP * i + DP * j) == N:
                return f"Yes"
    
    return f"No"

Submission status: Runtime Error

Solution code:
def Cakes_and_Donuts(N):
    CP = 4
    DP = 7
    
    if N <= 3:
        return f"No"
    
    for i in range(26):
        for j in range(15):
            if (CP * i + DP * j) == N:
                return f"Yes"
    
    return f"No"

Submission status: Runtime Error

Solution code:
def cakes_and_donuts(N=N):
  max_7_num = N//7
  max_4_num = N//4
  for i in range(max_7_num):
    for j in range(max_4_num):
      if 7*(i+1) + 4*(j+1) == N:
        return 'Yes'
  return 'No'

N = int(input())
s = cakes_and_donuts(N)
print(''.format(s))

Submission status: Runtime Error

Solution code:
def cakes_and_donuts(N=N):
  max_7_num = N//7
  max_4_num = N//4
  for i in range(max_7_num):
    for j in range(max_4_num):
      if 7*(i+1) + 4*(j+1) == N:
        return 'Yes'
  return 'No'

N = int(input())
cakes_and_donuts(N)

Submission status: Runtime Error

Solution code:
n =int(input())
for i in range(16):
    if (n%(i*7))%4==0:
        print("Yes")
        exit()
print("No")

Submission status: Runtime Error

Solution code:
n=int(input())

if n%4==0 or n%7==0 or n%11==0 or n%11==4 or n%11==7:
  print('Yes')
else:

Submission status: Runtime Error

Solution code:
N = int(intput())
l=[]

for i in range(26):
    for j in range(16):
        l.append(i*4+j*7):

if N in l:
    print('Yes')
else:
    print('No')

Submission status: Runtime Error

Solution code:
N = int(intput())

for i in range(26):
    for j in range(16):
        l.append(i*4+j*7):

if N in l:
    print('Yes')
else:
    print('No')

Submission status: Runtime Error

Solution code:
import sys
n = int(input())

if n%7 != 0 and n%4 != 0 and n%11 != 0:
    for a in range(25):
        for b in range(14):
            if n%(7*b + 4*a) == 0:
                print('No')
                sys.exit()
else:
    print('No')
    sys.exit()
print('Yes')

Submission status: Runtime Error

Solution code:
N = int(input())

for i in range(N // 4 + 1):
  for j in range(N // 7 + 1):
	if 4 * i + 7 * j == N:
      print("Yes")
      quit()
    else:
      pass
print("No")

Submission status: Runtime Error

Solution code:
N = int(input())
flag = 0

for cake in range(26):
    for donut in range(15):
        if cake*4 + donut*7 == N:
            flag = 1
            break
    if flag == 1:
        break

if flag = 1:
    print("Yes")
else :
    print("No")

Submission status: Runtime Error

Solution code:
N = int(input())

if (N%7)%4 == 0 or (N%4)%7 == 0
  print('Yes')
else:
  print('No')

Submission status: Runtime Error

Solution code:
import sys
n = int(input())
n2 = n
while n>0:
    if n % 4 == 0 or n % 7 == 0:
        print("Yes")
        sys.exit(1)
    n -= 7
while n2>0:
    if n2 % 4 == 0 or n2 % 7 == 0:
        print("Yes")
        sys.exit(1)
    n2 -= 4
print("No")

Submission status: Runtime Error

Solution code:
import sys
n = int(input())
n2 = n
while n>0:
    if n % 4 == 0 or n % 7 == 0:
        print("Yes")
        sys.exit(1)
    n -= 7
while n>0:
    if n % 4 == 0 or n % 7 == 0:
        print("Yes")
        sys.exit(1)
    n -= 4
print("No")

Submission status: Runtime Error

Solution code:
#ABC105B
N = int(input())
OK = False
for i in range(N/4):
    for j in range(N/7):
        if i*4 + j*7 == N:
            OK = True
if OK:
    print("Yes")
else:
    print("No")

Submission status: Runtime Error

Solution code:
#ABC105B
N = int(input())
OK = False
for i in range(N/4):
    for j in range(N/7):
        if i*4 + j*7 == N:
            flag = True
if OK:
    print("Yes")
else:
    print("No")

Submission status: Runtime Error

Solution code:
N = input()
flag = False
for i in range(N//4):
    for j in range(N//7):
        if 4 * i + 7 * j == N:
            flag = True
if flag:
    print("Yes")
else:
    print("No")

Submission status: Runtime Error

Solution code:
N = input()
flag = False
for i in range(N//4 + 1):
    for j in range(N//7 + 1):
        if 4 * i + 7 * j == N:
            flag = True
if flag:
    print("Yes")
else:
    print("No")

Submission status: Runtime Error

Solution code:
N = input()
flag = False
for i in range(N//4 + 1):
    for j in range(N//7 + 1):
        if 4 * i + 7 * j == N:
            flag = True
            break
if flag:
    print("Yes")
else:
    print("No")

Submission status: Runtime Error

Solution code:
N=int(input())
for i in range(26) :
  if N=>4 and (N-(4*i))%7==0 :
    print("Yes")
    break
else :
  print("No")

Submission status: Runtime Error

Solution code:
N = int(input())
a = N//4
b = N//7

judge = False
for i in range(a):
  for j in range(b):
    if 4*i+7*k == N:
      judge =True
      break
    if 4*i+7*j > N:
      break
  if judge:
    break

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

Submission status: Runtime Error

Solution code:
n=int(input())
a=[]
for x in range(15):
    for y in range(26):
        a.append(x*7+y*4)
if not n in a:
    print("No")
else:
    print("Yes)

Submission status: Runtime Error

Solution code:
n=int(input())
if n%11==0 or n%7==0 or n%4==0 or n%11==4 or n%7==4 n%11==7:
    print("Yes")
else:
    print("No")

Submission status: Runtime Error

Solution code:
N = input()
if (N%28)/4 == 0 or (N%28)/7 == 0:
    print("Yes")
else:
    print("No")

Submission status: Runtime Error

Solution code:
if (N%28)/4 == 0 or (N%28)/7 == 0:
  print("Yes")
else:
  print("No")

Submission status: Runtime Error

Solution code:
N = int(input())
for i in range(100):
    for j in range(100):
        if 4 * i + 7 * j == n:
            print("Yes")
            exit(0)
print("No")

Submission status: Runtime Error

Solution code:
def det(n):
    seven = range((n // 7) + 1)
    four = range((n // 4) + 1)
    for i in seven:
        for p in four:
            if (i*7 + p*4) == n:
                return 'Yes'
    return 'No'
x = int(input)
print(det(x))

Submission status: Runtime Error

Solution code:
def det(n)
    if n % 4 == 0:
        return 'Yes'
    elif n % 7 == 0:
        return 'Yes'
    elif n < 4 or (5 <= n and n <= 6):
        return 'No'
    seven = range(n//7 + 1)
    for i in seven:
        if (n - seven*7) % 4 == 0:
            return 'Yes'
    return 'No'
n = int(input())
print(det(n))

Submission status: Runtime Error

Solution code:
N = int(input())
answer = "No"

for x in range(N/4+1):
	for y in range(N/7+1):
  		if(4*x + 7*y == N):
    		answer = "Yes"
      		break

Submission status: Runtime Error

Solution code:
N = int(input())

for x in range(N/4)
	for y in range(N/7)
  		if(4*x + 7*y ==)
    		print("Yes")
      		break

Submission status: Runtime Error

Solution code:
def main():
  N = int(input())

  for i range(26):
    if i * 4 > N:
      break
    if (N - i * 4) % 7 == 0:
      print('Yes')
      return
  print('No')

if __name__ == '__main__':
  main()

Submission status: Runtime Error

Solution code:
def fits(N):
    if N < 4:
        return 'no'
    else:
        for cake in range(0,100,4):
            for donut in range(0,100,7):
                if cake + donut is N:
                    return 'yes'

if __name__ == '__main__':
    print(fits(int(N)))

Submission status: Runtime Error

Solution code:
n= int(input())
if 4*(2n//7) -n>=0:
    print("Yes")
else:
    print("No")

Submission status: Runtime Error

Solution code:
n=input()
while True:
  if n%4==0:
    print("YES")
    break
  n-=7
  if n<0:
    print("NO")
    break

Submission status: Runtime Error

Solution code:
n=input()
while True:
  if n%4==0:
    print("YES")
    exit()
  n-=7
  if n<0:
    print("NO")
    exit()

Submission status: Runtime Error

Solution code:
N = int(input())

counter = 0
for number_cake in range(0,N):
	if(((N-number_cake*4) % 7 == 0)&&(N >= number_cake*4)):
		counter += 1

if(counter > 0):
	print("Yes")
else:
	print("No")

Submission status: Runtime Error

Solution code:
import sympy
def piyo():
    n = int(input())
    if (n-7)%4==0 or (n-14)%4==0 or (n-21)%4==0 or n%4==0:
        print("Yes")
        return
    print("No")
        
if __name__ == '__main__':
    piyo()

Submission status: Runtime Error

Solution code:
a = int(input())
if a > 3:
	if a % 4 == 0 or a % 7 == 0 or a % 7 == 4 or a % 7 == 1 or a % 4 == 3:
        print("Yes")
    else:
        print("No")
else:
  print("No")

Submission status: Runtime Error

Solution code:
a = int(input())
if a > 3:
	if a % 4 == 0 or a % 7 == 0 or a % 7 == 4 or a % 7 == 1 or a % 4 == 3:
      print("Yes")
    else:
      print("No")
else:
  print("No")

Submission status: Runtime Error

Solution code:
import sys

def solve(a):
    # Uncomment the following if you want to check the input.
    print('a =', a)
     # replace with the answer
    if a<=3:
        return('No')
    else:
        return('Yes')

def readQuestion():
    ws = sys.stdin.readline().strip().split()
    a = int(ws[0])
    return (a)

def main():
    print(solve(*readQuestion()))

# Uncomment before submission
 main()

Submission status: Runtime Error

Solution code:
n = int(input())
for i in range(26):
    for j in range(16):
        if i*$ + j*7 == n:
            print('Yes')
            exit()

print('No')

Submission status: Runtime Error

Solution code:
a=int(input())
for i in range(26):
  for l in range(15):
    if 4*i+7*j==100:
      print("Yes")
      exit()
print("No")

Submission status: Runtime Error

Solution code:
if (N % 7) % 4 == 0 or (N % 4) % 7 == 0:
    print("Yes")
else:
    print("No")

Submission status: Runtime Error

Solution code:
import sys
n=int(input())
while(1):
    if(n%4=0):
        print("Yes")
        sys.exit()
    n-=7
    if(n<=3):
        break
print("No")

Submission status: Runtime Error

Solution code:
n=int(input())
if(n==3):
  print("No")
elif(n%4==0 or n%4==3):
  print("Yes"):
else:
  print("No")

Submission status: Runtime Error

Solution code:
n = int(input())
p = 0
for i in range(26)
  for j in range(16)
    if 4*i + 7*j == n:
      p == 1
      break
if p == 0:
  print("No")
else: 
  print("Yes")

Submission status: Runtime Error

Solution code:
N = int(input())
cake = 4
donut = 7
ac = False
for i in range(25):
    for j in range(14):
        if N == (cake * i + donut * j):
            ac = True
if ac:
    print('Yes')
else:
    print('No)

Submission status: Runtime Error

Solution code:
N = int(input())
cake = 4
donut = 7
ac = False
for i in range(25):
    for j in range(14):
        if N == (cake * i + donut * j):
            ac = True
            exit()
if ac:
    print('Yes')
else:
    print('No)

Submission status: Runtime Error

Solution code:
four_w = []
seven_w = []
cross = []

for i in range(0,100):
    if i % 4 == 0:
        four_w.append(i)
    elif i % 7 ==0:
        seven_w.append(i)

for four in four_w:
    for seven in seven_w:
        cross.append(four + seven)

n = int(input())

if n in cross:
    print("Yes")
elif n in seve_w:
    print("Yes")
elif n in four_w:
    print("yes")
else:
    print("No")

Submission status: Runtime Error

Solution code:
four_w = []
seven_w = []
cross = []

for i in range(1,100):
    if i % 4 == 0:
        four_w.append(i)
    elif i % 7 ==0:
        seven_w.append(i)

for four in four_w:
    for seven in seven_w:
        cross.append(four + seven)

n = int(input())

if n in four_w,seven_w,cross:
    print("Yes")
else:
    print("No")

Submission status: Runtime Error

Solution code:
n = int(input())
f = False
for i in range(int(n/4)):
    for j in range((n/7)):
      if 4*i + 7*j == n:
        f = True
if f:
  print('Yes')
else:
  print('No')

Submission status: Runtime Error

Solution code:
n = int(input())
ans = "No"

for i in range(100):
	for j in range(100):
		if i*7+j*4 == N:
			ans = "Yes"

print(ans)

Submission status: Runtime Error

Solution code:
n = int(input())
a = [1,2,3,5,6,9,10,13,17]
if n in a:
  print(No)
else:
  print(Yes)

Submission status: Runtime Error

Solution code:
n = int(input())
if n % 4 == 0: print('Yes')
elif n >= 7 && n % 4 == 3: print('Yes')
elif n >= 14 && n % 4 == 2: print('Yes')
elif n >= 21 && n % 4 == 1: print('Yes')
else: print('No')

Submission status: Runtime Error

Solution code:
N = int(input())
# N = 4n+7m 
if N % 4 == 0 or N % 7 ==　0 or N % 7 == 4:
  print("Yes")
else:
  print("No")

Submission status: Runtime Error

Solution code:
N = int(input())
# N = 4n+7m 
if N % 4 == 0 or N % 7 ==0 or N % == 4:
  print("Yes")
else:
  print("No")

Submission status: Runtime Error

Solution code:
N = int(input())

flag = False
for i in range(0,30):
  for j in range(0,30):
  	if i * 4 + j * 7 == N:
      flag = True

if flag == True:
  print('Yes')
else:
  print('No')

Submission status: Runtime Error

Solution code:
def calc(a):
  for a4 in range(26):
    for a7 in range(16):
      if a4*4+a7*7 is a:
        return "Yes"
  return "No"

if __name__ == '__main__':
  calc(int(input())

Submission status: Runtime Error

Solution code:
def calc(a):
  a = int(input())
  for a4 in range(26):
    for a7 in range(16):
      if a4*4+a7*7 is a:
        return "Yes"
  return "No"

if __name__ == '__main__':
  calc(int(input())

Submission status: Runtime Error

Solution code:
cake = []
donut = []
for i in range(1, 26):
	cake.append(i*4)
for i in range(1, 15):
	donut.append(i*7)

n = int(raw_input())

flag = false
if n in cake: flag = true
if n in donut: flag = true
if not flag:
	for i in range(0, len(cake)):
		for j in range(0, len(donut)):
			if n == cake[i] + donut[j]:
				flag = true
				break
		if flag: break

if flag: print 'Yes'
else: print 'No'

Submission status: Runtime Error

Solution code:
n =int(raw_input())
lis=[]
for i in range(1,26):
    lis.add(4*i)
for i in range(1,15):
    lis.add(7*i)
for i in range(1,20):
    for j in range(1,20):
        lis.add(4*i+7*j)
if n in lis:
    print "Yes"
else:
    print "No"

Submission status: Runtime Error

Solution code:
N=input()
for i in range(N / 7)
    print(N / 7*i %4==0)

Submission status: Runtime Error

Solution code:
N = int(input())

c=False
for (i in range(25)):
        for(j in range(7)):
            if(i*4+7*j==N):
                c=True
                break
if(c):
    print("Yes")
else:
    print("No")

Submission status: Runtime Error

Solution code:
n = int(input())
if n > 4:
	if n % 4 == 0 or n % 7 == 0 or n % 28 == 0 or n % 11 == 0:
  		print("Yes")
    else:
      print("No")
else:
	print("No")

Submission status: Runtime Error

Solution code:
import math
n=int(input())
count=0
while cakes*4+donuts*7<n:
    for a in range(math.floor(n/4)+1):
        if (n-a*4)%7==0:
            count+=1
print(count)

Submission status: Runtime Error

Solution code:
n = int(input())
flag = False
for x in range(100):
    for y in range(100):
        flag = (4*x+7*y==n)
if flag:
    print("Yes")
else
    print("No")

Submission status: Runtime Error

Solution code:
def canbuy(n):
    for i in range(int(100/7)):
        if (n-7*i)>3 and (n-7*i)%4==0:
            return 'Yes'
    return 'No'

n=input()
print(canbuy(n))

Submission status: Runtime Error

Solution code:
def canbuy(n):
    for i in range(int(100/7)):
        if (n-7*i)%4 == 0:
            return 'Yes'
    return 'No'

n=input()
print(canbuy(n))

Submission status: Runtime Error

Solution code:
def canbuy(n):
    if n%7==0 or n%4==0:
        return 'Yes'
    else:
        if n<4:
            return 'No'
        else:
            if canbuy(n-7)=='Yes':
                return 'Yes'
            else:
                if canbuy(n-4)=='Yes':
                    return 'Yes'
                else:
                    return 'No'

n=input()
print(canbuy(n))

Submission status: Runtime Error

Solution code:
if __name__ == "__main__":
    N = input()
    for x in range(0, 100):
        y = N - 4 * x
        if y % 7 == 0:
            print ("Yes")
            exit(0)
    print ("No")

Submission status: Runtime Error

Solution code:
n = int(input())

while(n >= 0):
    if n % 7 == 0:
        print("Yes")
        return
    n -= 4
print("No")

Submission status: Runtime Error

Solution code:
N = int(input())
while N > 0:
    if N % 4 == 0 or N % 7 == 0:
        flag = True
        break
    else:
        N -= 7
if flag == True:
    print("Yes")
else:
    print("No")

Submission status: Runtime Error

Solution code:
N = int(input())
 
if N in [1, 2, 3, 5, 6, 7, 9, 10, 13, 17]:
   print("Yes")
else:
   print("No")
N = int(input())

if N in [1, 2, 3, 5, 6, 7, 9, 10, 13, 17]:
   print("Yes")
else:
   print("No")

Submission status: Runtime Error

Solution code:
n=int(input());
f=0;
while n>=0:
  if n%7<1:f+=1;
  n-=4;
print(["No","Yes"][f])

Submission status: Runtime Error

Solution code:
N = map(int, input())

if N % 7 == 0:
    print("Yes")
elif N % 4 == 0:
    print("Yes")
elif N - 7 >= 0 and N - 7 % 4 == 0:
    print("Yes")
elif N - 14 >= 0 and N - 14 % 4 == 0:
    print("Yes")
elif N - 21 >= 0 and N - 21 % 4 == 0:
    print("Yes")
else:
    print("No")

Submission status: Runtime Error

Solution code:
N = input()

if N % 4 == 0:
    print("Yes")
elif N - 7>=0 and N - 7 % 4 == 0:
    print("Yes")
elif N - 14>=0 and N - 14 % 4 == 0:
    print("Yes")
elif N - 21>=0 and N - 21 % 4 == 0:
    print("Yes")
else:
    print("No")

Submission status: Runtime Error

Solution code:
import math

n = int(input())

if n % 7 == 0 || n % 4 == 0:
    print("Yes")
elif n % 7 % 4 == 0 || n % 4 % 7 == 0:
    print("Yes")
else:
    print("No")

Submission status: Runtime Error

Solution code:
import math

n = input()

if n % 7 == 0:
    print("Yes")
elif (n - math.floor(n/7)) % 4 == 0:
    print("Yes")
else:
    print("No")

Submission status: Runtime Error

Solution code:
N = int(input())
if N % 7 == 0:
	print('Yes')
else:
	while(N>0):
		if N%4 == 0:
			print('Yes')
			break
            else:
		N = N - 7
	else:
		print('No')

Submission status: Runtime Error

Solution code:
N = int(input())
if N % 7 == 0:
  print('Yes')
else:
  while(N>0):
  	if N%4 == 0:
      print('Yes')
      break
  	else:
    	N = N - 7
  else:
  	print('No')

Submission status: Runtime Error

Solution code:
N = int(input())
if N % 7 == 0:
  print('Yes')
else:
  while(N>0):
  	if N%4 == 0:
    	print('Yes')
    	break
  	else:
    	N = N - 7
  else:
  	print('No')

Submission status: Runtime Error

Solution code:
N = int(input())

if N%4 == 0:
    print("Yes")

if N%7 == 0:
    print("Yes")

if N%4 == 1:
    if N < 29:
        print("No")
    else:
        print("Yes")

if N%4 == 2:
    if N < 11:
        print("No")
    elif N < 15:
        print("No")
    else:
        print("Yes")

    
if N%4 == 3:
    if N > 10:
        print("Yes")
    else:
        print("N

Submission status: Runtime Error

Solution code:
# atcoder 105B
import fractions
import sys
 
def lcm(x, y):
    return (x * y) // fractions.gcd(x, y)
 
cake = 4
donut = 7
 
price = int(input())
 
if price%cake == 0 or price%donut == 0:
    print("Yes")
    sys.exit()
 
cake_donut_lcm = lcm(cake, donut)
answer_price = lcm(price, cake_donut_lcm)
 
if answer_price == price:
    print("Yes")
else:
    print("No")
# atcoder 105B
import fractions
import sys

def lcm(x, y):
    return (x * y) // fractions.gcd(x, y)

cake = 4
donut = 7

price = int(input())

if price%cake == 0 or price%donut == 0:
    print("Yes")
    sys.exit()

i = 1
j = 1
while cake+donut< price:
    while cake+donut<price:
        if cake+donut == price:
            print("Yes")
            sys.exit()
        j += 1
    j = 1
    i += 1
print("No")

Submission status: Runtime Error

Solution code:
if n < 4:
    print('No')
    exit()
                                                                                                                
for i in range(1, n % 7):
    tmp = n - 7 * i
    if tmp % 4 == 0:
        print('Yes')
        exit()
for i in range(1, n & 4):
    tmp = n - 4 * i
    if tmp % 7 == 0:
        print('Yes')
        exit()

print('No')

Submission status: Runtime Error

Solution code:
n = int(input())
f = 4
s = 7

for i in range(n):
    for n in range(n):
        if s + f == n:
            ans = 1
            break

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

Submission status: Runtime Error

Solution code:
# -*- coding: utf-8 -*-
n=raw_input().
ina=int(n)
des=0
for x in range(26):
    for y in range(16):
        ans=4*x+7*y
        if ans==ina:
            des=des+1
if des>0:
    print "Yes"
else:
    print"No"

Submission status: Runtime Error

Solution code:
N = int(input())
while(N>0):
  if N%4 == 0:
    print('Yes')
    return None
  else:
    N = N - 7
if N ==0:
  print('Yes')
else:
  print('No')

Submission status: Runtime Error

Solution code:
n = int(input())
x = 1+n//4
q = ['No','Yes']
s = 0
for a in range(x):
	if (n-a*4)%7==0:
    	s = 1
        
print(q[s])

Submission status: Runtime Error

Solution code:
N = int(input())
while(N>0):
  if N%4 == 0:
    print("Yes")
    return
  else:
    N = N - 7
if N ==0:
  print("Yes")
else:
  print("No")

Submission status: Runtime Error

Solution code:
n= input().strip().split()
n = int(n)

if n >= 4:
    print("Yes")
else:
    print("No")

Submission status: Runtime Error

Solution code:
# atcoder 105B
import math
import sys

def lcm(x, y):
    return int((x * y) / math.gcd(x, y))

cake = 4
donut = 7

price = int(input())

if price%cake == 0 or price%donut == 0:
    print("Yes")
    sys.exit()

cake_donut_lcm = lcm(cake, donut)
answer_price = lcm(price, cake_donut_lcm)

if answer_price == price:
    print("Yes")
else:
    print("No")

Submission status: Runtime Error

Solution code:
N = int(input())
import numpy as np
a = np.array((26,15))
for i in range(26):
  for j in range(15):
    a[i][j] = 4 * i + 7 * j

if N in a:
  print('Yes')
else:
  print('No')

Submission status: Runtime Error

Solution code:
# coding: utf-8
# Your code here!

# atcoder 105B
import math

def lcm(x, y):
    return int((x * y) / math.gcd(x, y))

cake = 4
donut = 7

price = int(input())

if price%cake == 0 or price%donut == 0:
    print("Yes")
    return 0

cake_donut_lcm = lcm(cake, donut)
answer_price = lcm(price, cake_donut_lcm)

if answer_price == price:
    print("Yes")
else:
    print("No")

Submission status: Runtime Error

Solution code:
n=int(input())
if n>=4:
    if n%4==0 or n%4==3 or n%7==0 or n%7==1 or N%7==5:
        print('Yes')
    else:
        print('No')
else:
    print('No')

Submission status: Runtime Error

Solution code:
n = input()
if n >= 20 or n % 7==0 or n%4==0 or n == 19 or n == 18 or n == 15 or n == 11:
    print("Yes")
else:
    print("No")

Submission status: Runtime Error

Solution code:
n=int(input())
if n>=4 and ( n%4==0 or n%4==3 or n%7==0 or n%7==1 or N%7==5 ):
    print('Yes')
else:
    print('No')

Submission status: Runtime Error

Solution code:
N = int(input())
q = 0
flug = 0
while q <= N :
        if N%7 == 0:
                flug = 1
                break
	if N - q % 4 == 0:
		flug = 1
		break
	q = q + 7

if flug == 1:
	print("Yes")
else:
	print("No")

Submission status: Runtime Error

Solution code:
n = map(int, input())
if n >= 20 or n % 7==0 or n%4==0 or n == 19 or n == 18 or n == 15 or n == 11 or n == 1:
    print("Yes")
else:
    print("No")

Submission status: Runtime Error

Solution code:
N = input()

if N%4 == 0:
    print("Yes")
    exit()

if N%7 == 0:
    print("Yes")
    exit()

S = N%7
K = (S%4)%2

if K == 0:
    print("Yes")
else:
    print("No")

Submission status: Runtime Error

Solution code:
# atcoder 105B
import math

def lcm(x, y):
    return int((x * y) / math.gcd(x, y))

cake = 4
donut = 7

price = int(input())

cake_donut_lcm = lcm(cake, donut)
answer_price = lcm(price, cake_donut_lcm)

if answer_price == price:
    print("Yes")
else:
    print("No")

Submission status: Runtime Error

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

if N%4 == 0:
    print("Yes")
    exit()

if N%7 == 0:
    print("Yes")
    exit()

S = N%7
K = (S%4)%2

if K == 0:
    print("Yes")
else:
    print("No")

Submission status: Runtime Error

Solution code:
# atcoder 105B
import math

def lcm(x, y):
    return (x * y) // math.gcd(x, y)

cake = 4
donut = 7

price = int(input())

cake_donut_lcm = lcm(cake, donut)
answer_price = lcm(price, cake_donut_lcm)

if answer_price == price:
    print("Yes")
else:
    print("No")

Submission status: Runtime Error

Solution code:
import numpy as np
a = int(input())
c = np.zeros(a)
for i in range(7):
	if(i == 3 or i == 6):
		c[i] = 1
#print(c)
for i in range(7, 40):
	if(c[i-4] == 1 or c[i-7] == 1):
		c[i] = 1
if(c[-1] == 1):
	print("Yes")
else:
	print("No")

Submission status: Runtime Error

Solution code:
n = int(input())
i = 0
flag = false
while(7*i<=n):
  if (n-7*i)%4 == 0:
    flag = true
    break
  i+=1
if flag:
  print("Yes")
else:
  print("No")

Submission status: Runtime Error

Solution code:
N = list(map(int, input().split()))
S = N%4

if S == 0:
    print("Yes")
elif S == 3:
    print("Yes")
else:
    print("No")

Submission status: Runtime Error

Solution code:
N = list(map(int, input().split()))
S = N%4

if S == 0:
    print("Yes")
elif S == 3::
    print("Yes")
else:
    print("No")

Submission status: Runtime Error

Solution code:
from math import floor

def main():
    n = int(input())

    for i in range(110):
        dp.append(10000000)
    dp[0] = 0

    seven = floor(n/7)
    for i in range(seven+1):
        mod = n - i*7
        if mod % 4 == 0:
            print('Yes')
            return
    print('No')


main()

Submission status: Runtime Error

Solution code:
N=int(input())

if N%7==0 or N%4==0 or N%7==4 or N%4==7 N%11==0 or N%11==4 or N%11==7:
  print('Yes')
else:
  print('No')

Submission status: Runtime Error

Solution code:
N = list(map(int, input().split()))
S = N%4

if S == 0 or S == 3:
    print("Yes")
else:
    print("No")

Submission status: Runtime Error

Solution code:
n = int(input())
i = 0
flag = false
while(7*i<=n):
  if (n-7*i)%4 == 0:
    flag = true
    break
if flag:
  print("Yes")
else:
  print("No")

Submission status: Runtime Error

Solution code:
N = int(input())
ans = 0
​
for i in range(1,26):
  for j in range(1,15):
    n = 4*i + 7*j
    if n == N:
      ans = 1
      break
      
if ans == 1:
  print("Yes")
else:
  print("No")