peterverebics/CodeNet_Python_118 huggingface dataset:
import math
k = int(input())
sum = 0
for a in range(1,k+1):
  for b in range(1,k+1):
    ab = math.gcd(a,b)
    for c in range(1,k+1):
      sum += math.gcd(ab,c)
print(sum)
n=str(input())
print(n[0])
if n[0]=="7":
  print("Yes")
elif n[1]=="7":
  print("Yes")
elif n[2]=="7":
  print("Yes")
else:
  print("No")
n = int(input())
a = n % 10
b = ((n - a) // 10) % 10
c = ((n - a - 10 * b) // 10) % 10
if (a == 7 or b == 7 or c == 7) :
    print("Yes")
else:
    print("No")
x=input()
for i in x:
  if i=="7":
    print("Yes")
else:
  print("No")
n = str(input())

ans = 'No'

for i in range(len(n)):
    if n[i] == '7':
        ans = 'Yes'

print('Yes')
# import single number
def import_number():
    return int(input())

# import n line int
def import_int(n):
    return [int(input()) for i in range(n)]

n = import_number()
tmp = n % 100
if n / 100 == 7:
    print('Yes')
elif tmp / 10 == 7:
    print('Yes')
elif tmp % 10 == 7:
    print('Yes')
else:
    print('No')
n = str(input())
if n[0] or n[1] or n[2] != 7:
    print("No")
else:
    print("Yes")
n = int(input())
k = 1
while(n != 0):
  m = n % 10
  n /= 10
  if(m == 7):
    k = 2
    break
if k == 2:
  print('Yes')
else: 
  print('No')
n = input()
for i in n:
    if i == "7":
        print("Yes")
        exit()
    else:
        print("No")
def fizzbuzz(n):
    ans = 0
    for i in range(n):
        if (i+1)%3 != 0 and (i+1)%5 != 0:
            ans += i+1
            # print(i+1, ans)
    print(ans)

n = int(input())
fizzbuzz(n)
N = int(input())
count = 0
for n in range(N+1):
  if (n%5)*(n%3) != 0:
    count += n
print(count)
s = 0
k = int(input())

def gcd(p,q):
    if p%q == 0:
        return q
    return gcd(q, p%q)
    
for a in range(1,k+1):
    for b in range(1,k+1):
        for c in range(1,k+1):
            s += gcd(gcd(a,b),c)
            
print(s)
S = input()
length = len(S)
for i in range(length):
  if S[i] == '7':
    print("Yes")
    break
N = int(input())
 
 
# M=1
# A=[5,4,2,1]
 
cnt = 0
cnt1 = 0
 
# for i in range(N):
#     cnt = cnt + A[i]
#
# for i in range(N):
#     if A[i] / cnt > 1 / 4 / M:
#         cnt1 = cnt1 + 1
 
a1 = N % 10
a2 = ((N-a1*10) % 100)//10
a3 = ((N-a1*100-a2*10))//100
 
if a1 == 7 or a2 == 7 or a3 == 7:
    print('Yes')
else:
    print('No')
N = str(input())

# print(N)

if '7' in N :
  print("YES")
else:
  print("NO")
n = list(map(str, input()))
ans = "NO"
for i in range(len(n)):
    if n[i] =="7":
        ans = "YES"
        break
print(ans)
# A Lucky 7

N = input()

for n in N:
  if n == "7":
    print("Yes")
else:
  print("No")
from math import gcd
k = int(input())
ans = 0
for i in range(1, k+1):
    for j in range(1, k+1):
        for l in range(1, k+1):
            ans += gcd(gcd(i, j), l)
print(ans)
R=input()
print("yes" if R[0]=="7" else "yes" if R[1]=="7" else "yes"if R[2]=="7"else "no")
N = int(input())
re = 0
for i in range(N):
    if i % 3 == 0 or i % 5 == 0:
        re = re + 0
    else:
        re = re + i
print(re)
n = input()
N = list(str(n))
if 7 in N:
    print('Yes')
else:
    print('No')
A = input("3numbers")
if A in [7]:
    print("yes")
else:
    print("no")
n=int(input())
a=n//100
b=n-a*100
c=n%10
if a==7 or b==7 or c==7:
    print("Yes")
else:
    print("No")
#A
N = list(input())
if any(N) ==7:
    print('Yes')
else:
    print('No')
N=int(input())

N=str(N)

if N[0]==7:
  print("Yes")
  
elif N[1]==7:
  print("Yes")

elif N[2]==7:
  print("Yes")
  
else:
  print("No")
N=input()
if N[0] == '7' or N[1] == 7 or N[2] == '7':
    print("Yes")
else:
    print("No")
no = int(input())
c = 0
while no > 0:
  if no%10 == 7:
    c = 1
  no = no/10
if c == 1:
  print("Yes")
else :
  print("No")
if __name__ == "__main__":
  n = input()
  if '7' in n:
  	print('yes')
  else:
  	print('no')
n = int(input(""))
c=n%100
d=n%10
u=n%1
if c==7 or d==7 or u==7:
    print("Yes")
else:
    print("No")
x = int(input())

if x % 3 == 0 and x % 5 == 0:
    print('FizzBuzz')
elif x % 3 == 0 and x % 5 != 0:
    print('Fizz')
elif x % 3 != 0 and x % 5 == 0:
    print('Buzz')
else:
    print(x)
import sys

def lucky_seven(num_string):
  for num in line:
    if num == '7':
      return 'YES'
  return 'NO'

for line in sys.stdin:
  lucky_seven(line)
n=int(input())
# a,b,c=map(int,input().split())
cnt=0
def gcd(a,b):
    if a==0: return b
    else: return gcd(b%a,a)
# print(gcd(a,b))

def gcd_3(a,b,c):
    if gcd(a,b)==0: return c
    else: return gcd(c % gcd(a,b),gcd(a,b))

for i in range(1,n+1):
    for j in range ( 1 , n + 1 ):
        for k in range ( 1 , n + 1 ):
            # print(i,j,k)
            cnt+=gcd_3(i,j,k)
print(cnt)
N = input()
if N[0] == "7" or N[1] == "7" or N[2] == "7" : print ("yes")
else:print ("no")
def check_has_7(i):
    for n in range(len(str(i))):
        print(str(i)[n])
        if(str(i)[n] == '7'):
            return "Yes"
    return "No"

a = int(input())
print(format(check_has_7(a)))
N= str(input())
if N.count("7")>=1:
	print ("yes")
else : 
  	print("No")
n = input()
ans=0
for i in n:
    if i==7:
        ans=1
if ans==1:
    print("Yes")
else:
    print("No")
n = int(input())

ans = 0

for i in range(0,3):
    if (n % 10) % 7 == 0:
        ans = 1
        break
    else:
        n = int(n/10)

if ans == 1:
    print('Yes')
else:
    print('No')
N=input()
counts=0
for i in range(0,len(N)):
    #print(N[i])
    if N[i]=='7':
        counts+=1
        #print(counts)   
        
    else:
        counts=+0
#print(counts)   
if counts>0:        
    print('Yes')
else:
    print('No')
n=int(input())
a=n-n%100
b=n%100-n%10
c=n%10
if a==7 or b==7 or c==7:
    print("Yes")
else:
    print("No")
from math import gcd
r=range(1, int(input()) + 1)
print(sum(gcd(gcd(a, b), c) for a in r for b in r for c in r))
import sys
import heapq, math
from itertools import zip_longest, permutations, combinations, combinations_with_replacement
from itertools import accumulate, dropwhile, takewhile, groupby
from functools import lru_cache
from copy import deepcopy

N = int(input())

if N % 10 == 7 or N // 10 % 10 == 7 or N // 10 % 10 == 7:
    print("Yes")
else:
    print("No")
import sys
sys.setrecursionlimit(99999999)

inputno = input()

sum = 0
for i in range(int(inputno)):
  
  if (i % 3 != 0) and (i % 5 != 0):
    sum += i  
  
print(sum)
a, b, c = input()
if a == 7:
    print('Yes')
elif b == 7:
    print('Yes')
elif c == 7:
    print('Yes')
else:
    print('No')
import math
from functools import reduce

def gcd_get(*numbers):
    return reduce(math.gcd, numbers)

K = int(input())

ans = 0
for i in range(1, K+1):
    for j in range(1, K+1):
        for l in range(1, K+1):
            ans += gcd_get(i, j, l)
print(ans)
l = [int(x) for x in input()]

if l[0] == 7 or l[1] == 7 or l[2] == 7:
    print('YES')
else:
    print('NO')
n = int(input())
 
n = str(n)
 
flag = 0
 
for i in n:
  if(i != '7'):
    flag = 0
  else:
    flag = 1
 
    
if flag == 0:
  print('No')
else :
  print('Yes')
N = int(input())
h = N % 100
t = (N - h*100) % 10
o = N - h*100 - t*10
if h == 7 or t == 7 or o == 7:
    print("Yes")
else:
    print("No")
N = str(input())

list = [N[0], N[1], N[2]]
if 7 in list:
  print("Yes")
else:
  print("No")
num = [int(x) for x in input().split()]

for n in num:
    if n == 7:
        print("Yes")
        break
    elif n != 7:
        print("No")
K = int(input())

import itertools
import math
from functools import reduce

def gcd_list(numbers):
    return reduce(math.gcd, numbers)

lis = [i for i in range(1,K+1)]
s = 0
for team in itertools.product(lis, repeat = 3):
    s += gcd_list(team)
print(s)
import time
startTime = time.time()

N = 476
s = str(N)
b = "No"
if "7" in s:
    b = "yes"
print(b)

endTime = time.time()
elapsed_time = endTime-startTime
print(f"経過時間：{elapsed_time}")
s = list(input())
# print(s[0])
if int(s[0])%7==0 or int(s[1])%7==0 or int(s[2])%7==0:
    print('Yes')
else:
    print('No')
n = int(input())

a = int(n / 100)

b = int(n % 100 / 10)
c = int(n % 10)

print(b)
if 7 in (a, b, c):
  print('Yes')
else:
  print('No')
from math import gcd

k = int(input())
ans = 0
for l in range(1,k+1):
  for m in range(1,k+1):
    for n in range(1,k+1):
      ans += gcd(gcd(l,m),n)

print(ans)
n = input()
#print(n[1])
if n[0] =='7' or n[1] == '7' or n[2] == '7':
    print('YES')
else:
    print('NO')
n = int(input())
for i in range(3):
    if n%10 == 7:
        print('Yes')
        exit()
    else:
        n // 10
print('No')
N = input()
for i in range(3):
    flag = False
    if N[i] == "7":
        flag = True
if flag == True:
    print("Yes")
else:
    print("No")
N = int(input())
if  N % 10 == 7:
  print("Yes") 
elif  N % 100 == (70 or 71 or 72 or 73 or 74 or 75 or 76 or 77 or 78 or 79):
  print("Yes")
elif  N - (N % 100) == 700:
  print("Yes")
else:
  print("No")
N = int(input())
l = []
for i in range(N):
    if i % 3 == 0:
        l.append("Fizz")
    elif i % 5 == 0:
        l.append("Buzz")
    else:
        l.append(i)
re = 0
for j in l:
    if j == "Fizz" or j=="Buzz":
        re = re + 0
    else:
        re = re + j
print(re)
n = list(input())
if 7 in n:
  print("Yes")
else:
  print("No")
n = str(input())
a = str(7)
if n in a:
  print('Yes')
else:
  print('No')
import math
from functools import reduce
a=1;b=1;c=1;d=0
n=int(input());
for i1 in range(n):
	for i2 in range(n):
		for i3 in range(n):
			d+=reduce(math.gcd,(a,b,c))
			c+=1
		b+=1;c=1
	a+=1;b=1
print(d)
N = sorted(input())

if N[0]=='7':
    print('yes')
elif N[1]=='7':
    print('Yes')
elif N[2]=='7':
    print('Yes')
else:
    print('No')
n=int(input())
a=n//100
b=(n-a*100)//10
c=n%100
ans="Yes"
if a!=7 and b!=7 and c!=7:
  ans="No"
print(ans)
N=input()
if N.find('7')==1:
    print('Yes')
else:
    print('No')
N = input()
if N in '7':
    print('Yes')
else:
    print('No')
N = input()
length_N = len(N)
count = 0

for i in range(length_N):
    if N[i] == '7':
        print('yes')
        count += 1
        break
    
if count == 0:
    print('no')
digits = input()
if '7' in digits:
    print('yes')
else:
    print('no')
n=list(input())
for i in range(len(n)):
	if n[i]=="7":
		print("Yes")
		exit()
	else:
		print("No")
		exit()
N = int(input())
x=N/100
y=N%100/10
z=N%100%10
if (7 in [x, y, z]):
    print('Yes')
else:
    print('No')
N = int(input())
if N // 100 == 7 or N // 10 == 7 or N % 10 == 7:
  print('Yes')
else:
  print('No')
N=int(input())
N1=N//100
N2=(N//10)%10
N3=N%10
if N1==7 or N2==7 or N3==7:
    print("YES")
else:
    print("NO")
from math import gcd


def solve():

    K = int(input())

    rangeK = range(1, K+1)
    ans = 0

    for a in rangeK:
        for b in rangeK:
            for c in rangeK:
                ans += gcd(gcd(a, b), c)

    print(ans)


if __name__ == "__main__":
    solve()
N = input()
print('YES') if N.count('7') else print('NO')
import numpy as np
N=input()
if (N[0]=="7"):
    print("yes")
elif (N[1]=="7"):
    print("yes")
elif (N[2]=="7"):
    print("yes")
else:
    print("No")
s = "input()"
if s[0] is "7":
  print("Yes")
elif s[1] is "7":
  print("Yes")
elif s[2] is "7":
  print("Yes")
else:
  print("No")
string=input()
t=False
for i in range (len(string)):
  if string[i]=="7":
    t=True
if t==True:
  print("YES")
else:
  print("NO")
n=int(input())


if(n/100)==7 or (n/10)%10 ==7 or (n%10)==7 :
    print('Yes')
else : 
    print('No')
import math
#数値ひとつ
#I = int(input())
#数値欲しいとき
#H, W = map(int, input().split())
#文字欲しいとき
str = input()


list = str.split()

bool = False
for a in list:
    if a == '7':
        bool = True
        break

if bool == True:
    print('Yes')
else:
    print('No')
import numpy as np
N = int(input())
if N >= 2 :
    An = np.zeros(N+2)
    #An = [[] for _ in range(1,N+2)]
    #print(An)
    for s in range(1,N+1) :
        #print(s)
        if s%3 != 0 and s%5 != 0 :
            An[s] = int(s) 
            #print(s)
            #print(An[s])
    ans = np.sum(An)

else:
    ans = int(1)

print (int(ans))
n = list(map(int, input().split()))
if 7 in n:
    print('Yes')
else:
    print('No')
from sys import stdin


if __name__ == "__main__":
    _in = [_.rstrip() for _ in stdin.readlines()]
    N = _in[0] # type:str
    # vvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvv
    TF = True if '7' in N else False
    # ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
    print(TF)
import math as mat
N = int(input())
A = int(mat.floor(N/100))
B = int(mat.floor((N-A*100)/10))
C = int(mat.floor(N-A*100-B*10))
if A == 7 or B == 7 or C == 7 :
    ans = 'yes'
else:
    ans = 'no'

print(ans)
a=input()
flag=0
if a[0]==7:
  flag=1
if a[1]==7:
  flag=1
if a[2]==7:
  flag=1
if flag==1:
  print("Yes")
else:
  print("No")
a = list(input())
if(a.count('7') > 0):
    print("YES")
else:
    print("NO")
n=int(input())

ans='No'

if n//100==7 or n//10==7 or n%10==7:
    ans='Yes'
else :
    ans='No'
print(ans)
N = int(input())
sum = 0

for i in range(N):
    if (i + 1) % 3 != 0 and (i + 1) % 5 != 0:
        sum += (i + 1)

print(sum)
N = str(input())
if N[0] == 7:
    print('Yes')
elif N[1] == 7:
    print("Yes")
elif N[2] == 7:
    print("Yes")
else:
    print("No")
n=int(input())
if n // 100 == 7:
    print('Yes')
elif n // 10 == 7:
    print('Yes')
elif n % 10 == 7:
    print('Yes')
else:
    print('No')
n = input().split()
n_1 = [int(i) for i in n]

if 7 in n_1:
  print('Yes')
else:
  print('No')
n = input().split()
for i in range(len(n)):
    if ('7'==n):
        print("Yes")
print("No")
import sys

read = sys.stdin.buffer.read
readline = sys.stdin.buffer.readline
readlines = sys.stdin.buffer.readlines

N = str(sys.stdin.read())
flag = False

for s in N:
    print(s)

    if s == '7':
        flag = True

if flag:
    print('Yes')
else:
    print('No')
import math

K = int(input())
sumGCD = K * K * K
for a in range(2, K + 1, 1):
    for b in range(2, K + 1, 1):
        for c in range(2, K + 1, 1):
            arr = [a, b, c]
            gcdNum = math.gcd(math.gcd(a, b), c)
            # if gcdNum != 1:
            # print(arr)
            # print(gcdNum)
            sumGCD += gcdNum - 1
print(sumGCD)
import sys
def input(): return sys.stdin.readline().rstrip()

N = input()

print(N)
if '7' in N:
    print('Yes')
else:
    print('No')
N = int(input())

n100 = int(N/100)
n10 = int((N-n100*100)/10)
n1 = int(N - n100*100 - n10*10 )
print(n100, n10, n1)
if n100==7 or n10==7 or n1==7 :
    print('Yes')
else:
    print('No')
n = input()

if '7' in n:
  print('Yes')
else:
  print('False')
s = "117"
if s.find("7") != -1:
    print ("Yes")
else:
    print ("No")
n=int(input())
sum=0
for i in range(n+1):
  if i%3!=0 and i%5!=0:
    sum+=i
    
print(sum)
N=input()
n=list(N)
x= '7' in n
if x is True:
  print("yes")
else:
  print("no")
from math import gcd
K=int(input())+1
sum=0
for a in range(1,K):
    for b in range(1,K):
        for c in range(1,K):
            AB = gcd(a,b)
            BC = gcd(b,c)
            ABC = gcd(AB,BC)
            sum = sum+ABC
print(sum)
def lucky7(n):
  if '7' in str(n):
    return 'Yes'
  else:
    return 'No'
N = int(input())
total = 0
for i in range(1, N + 1):
    if i % 3 == 0 or i % 5 == 0:
        total += i
print(total)
n=int(input())
f=1
while n>0:
  if n%10==7:
    print("Yes")
    break;
  else:
    f=0
  n/=10
if f==0:
  print("No")
n=input().count('7')
if n>0:
  print('YES')
else:
  print('NO')
import io
import sys

# input here
_INPUT = """\
123
"""
sys.stdin = io.StringIO(_INPUT)

n = input().count('7')
if n == 0:
    ans = 'No'
else:
    ans = 'Yes'

print(ans)
n = str(input())
keta1 = n[0]
keta2 = n[1]
keta3 = n[2]
if keta1 != 7:
  if keta2 != 7:
    if keta3 != 7:
      print("No")

else:
  print("Yes")
import math
K = int(input())
S = 0
for a in range(1,K+1):
    for b in range(1,K+1):
        for c in range(1,K+1):
            S += math.gcd(math.gcd(a,b),c)
print(S)
n = input()
if "7" in n:
  print("Yes")
else:
  print("NO")
n=int(input())

if n%10==7 or n/10%10==7 or n/100==7:
    print("Yes")
else:
    print("No")
n = input()
if '7' in n:
  print("Yes")
else:
  print("NO")
from math import gcd
K=int(input())+1
sum=0
for a in range(1,K):
    for b in range(1,K):
        for c in range(1,K):
            AB = int(gcd(a,b))
            BC = int(gcd(b,c))
            ABC = int(gcd(AB,BC))
            sum = sum+ABC
print(sum)
n=int(input())
a=n//100
b=(n-a*100)//10
c=n%10
print(a,b,c)
if a==7 or b==7 or c==7:
    print("Yes")
else:
    print("No")
N=input()
if N[0]==7 or N[1]==7 or N[2] ==7: 
    print('Yes') 
else: 
    print('No')
n=list(map(int,input().split()))

if 7 in n:
  print("Yes")
else:
  print("No")
s = input()
if s.find("7") == -1:
  print('No')
else:
  print('yes')
N= str(input())
if "7" in N:
    print("YES")
else:
    print("NO")
r=int(input())
c=0
if r>699 and r<800:
    c+=1
r=r%100
if r>69 and r<80:
    c+=1
r=r%100
if r==7:
    c+=1


if c>0:
    print("Yes")
if c==0:
    print("No")
N=str(input())
if N[0]==7 or N[1]==7 or N[2]==7:
	print('Yes')
else:
	print('No')
N=int(input())
A=str(N)
if all(s!=7 for s in A):
  print("No")
else:
  print("Yes")
N = int(input())
x = N
while x:
    if x % 10 == 7:
        print('Yes')
    x //= 10
print('No')
s=input()
if "7" in s:
   print("YES")
else:
  print("NO")
if '7' in list(input()):
    print('yes')
else:
    print('No')
N = int(input("N = "))
if 100 <= N <= 999:
        if "7" in str(N):
            print("Yes")
        else:
            print("No")
n = input()

if(n[0]=='7' and n[1]=='7' and n[2]=='7'):
    print('Yes')
else:
    print('No')
N = int(input( ))
b = N % 10
if (b == 7):
	print("yes")
else:
	print("NO")
N = list()
if "7" in N:
    print("Yes")
else:
    print("No")
N = int(input())
  
n100 = int(N/100)
n10 = int((N-n100*100)/10)
n1 = int(N - n100*100 - n10*10 )
print(n100, n10, n1)
if n100==7 or n10==7 or n1==7 :
	print('Yes')
else:
	print('No')
def find_7(num):
	num_list = list(map(int, str(num)))
	count = 0
	for x in num_list:
		count += 1
		if x == 7:
			return "Yes"
		elif count == len(num_list):
			return "No"
n = input()
c=0
for x in n:
    if x=="7":
        print("Yes")
        c+=1
        break
    else:
        pass
if c!=3:
    print("No")
x = list(input())
j = 0
for i in x:
  print(i)
  if int(i) != 7:
    j = 1

if j == 0:
  print('Yes')
else:
  print('No')
n = input()
li = list(n)
t = False
for i in li:
    if i == '7':
        t= True

print(t)
number=int(input())
identifier=0
if number%10==7:
  identifier =1
elif number%100==7:
  identifier=1
elif number%1000==7:
  identifier=1
else:
  identifier=0
if identifier ==1:
  print("Yes")
else:
  print("No")
def main():
    N = input()
    flag = False
    for i in N:
        if int(i) % 7 == 0:
            flag = True
    if flag:print("Yes")
    else:print("No")

if __name__ == "__main__":
    main()
n = int(input())
ans = 0
for i in range(n+1):
    if i%15!=0 and i%3!=0 and i%5!=0:
        ans += i
print(ans)
N=input()
for idx in range(len(N)):
  if N[idx] == 7:
    print('Yes')
    break
else:
  print('No')
N = int(input())
S = 0
for i in range(0,N):
  if (i+1) % 3 != 0 and (i+1) % 5 != 0:
    S = S + i+1
print(S)
N = str(input())
if "7" in "N":
  print("Yes")
else:
  print("No")
s = input().split()
ans = 'No'
for e in s:
  if e == '7':
    ans = 'Yes'
    break
print(ans)
n = input()
for i in n:
    if i == 7:
        print('Yes')
    else:
        print('No')
N = str(input())
flag = True
for i in range(len(N)):
    if N[i] == "7":
        flag = True
        
if flag:    
    print("Yes")
else:
    print("No")
n=int(input())
f=0
c=0
while n>0:
      c=n%10
      if c==7:
           f=1
           print("Yes")
      n=n/10
if f==0:
      print("No")
n=str(input())
if n.find("7"):
    print("Yes")
else:
    print("No")
n = int(input())
first = n // 100
second = (n % 100) // 10
third = (n % 10)

if (first == 7 or second == 7 or third == 7):
  print('YES')
else:
  print('No')
N = input()
flag = 0
for i in N:
    if i == '7':
        flag = 1
        print('yes')
        break
if flag == 0:
    print('no')
a = int(input())
for  _ in range(3):
	if a % 10 == 7:
		print("Yes")
		break
	a /= 10
else:
	print("No")
#return
n = input()
ans = 'No'
for i in range(3):
    n[i] == '7'
    ans = 'Yes'
print(ans)
n = str(input())
if '7' in n:
    print("yes")
else:
    print("no")
#文字列の入力
S = input()

S_list = list(S)

ans = 0
for i in range(len(S_list)):
  if(S_list[i] == "7"):
    ans = 7
  else:
    ans = 0
    
    
    
if(ans == 7):
  print("Yes")
else:
  print("No")
#coding:utf-8 
# 検索したい文字列 
N=input()
if N[0] or N[1] or N[2] ==7: 
    print('Yes') 
else: 
    print('No')
n = input()
if n[0] == 7 or n[1]==7 or n[2]==7 in str(n):
    print("yes")
else:
    print("No")
A = input()
for i in range(len(A)):
    if A[i] == '7':
        YN = 'Yes'
    else:
        YN = 'No'
print(YN)
N = str(input())
flag = 0

for i in range(3):
    if N[i] == 7:
        flag = 1

if flag == 1:
    print('Yes')
else:
    print("No")
s = input()
if '7' in s:
  print('YES')
else:
  print('NO')
a=str(input())
if a[0] ==7 or a[1] ==7 or a[2]==7:
    print("Yes")
else:
    print("No")
import sys
 
X = input()
test = list(X)
print(test)
for num in test:
  tmp = int(num)
  if tmp == 7:
    print("Yes")
    sys.exit()
print("No")
def fizz_buzz(n):
    total = 0
    for i in range(1,n+1):
        if i % 15 == 0:
            continue
        elif i % 3 == 0:
            continue
        elif i % 5 == 0:
            continue
        else:
            total += i
    return total


if __name__ == "__main__":
    n = int(input())
    print(fizz_buzz(n))
def u(a,b):
  if(a<b):
    z = b
    b = a
    a = z
  r = a % b
  while(r!=0):
    a = b
    b = r
    r = a % b
  return b
 
l = int(input())
s = 0
for i in range(1,l+1):
  for i2 in range(1,l+1):
    z = u(i,i2)
    for i3 in range(1,l+1):
      z2 = u(z,i3)
      s+=z2
print (s)
a = int(input( ))
b = a % 10
if (b == 7):
	print("yes")
else:
	print("NO")
n = int(input())
if 7 in range(n):
    print("Yes")
else:
    print("No")
n  = input()
print(n[0])
print(n[1])
print(n[2])
if (int(n[0]) != 7 and int(n[1]) != 7 and int(n[2]) != 7):
  print('No')
else:
  print('Yes')
N=input()
if N[0]==7:
  print("Yes")
elif N[1]==7:
  print("Yes")
elif N[2]==7:
  print("Yes")
else:
  print("No")
import math

K = int(input())
ans = 0

for i in range(K):
    for j in range(K):
        for k in range(K):
            ans += math.gcd(math.gcd(i+1, j+1), k+1)

print(ans)
def main():
  n = int(input())
  flag = 0
  while n > 0:
      if n % 10 == 7:
          flag += 1
      n /= 10
  if flag > 0:
      print('Yes')
  else:
      print('No')
main()
a_string = input()
a_list = a_string.split()
map_object = map(int, a_list)


list_of_integers = list(map_object)
ans = "No"
for i in range(0 , len(list_of_integers)):
  if list_of_integers[i] == "7":
    ans = "Yes"
    break
print(ans)
N = int(input())
answer = 0
for i in range(1, N+1):
    if i % 3 != 0 and i % 5 != 0:
        answer = answer + i
print(answer)
N=int(input())
if N/100==7:
	print("Yes")
elif N%100/10==7:
	print("Yes")
elif N%10==7:
	print("Yes")
else:
	print("No")
N = input()
if N.count == 0:
  print("No")
else:
  print("Yes")
n = [input()]
if 7 in n:
    print("Yes")
else:
    print("No")
fizz = []
buzz = []
fizzbuzz = []
other = []
n = int(input())
for i in range(n):
    if (i % 3 != 0) & (i % 5 != 0):
        other.append(i)

b = 0
for i in range(len(other)):
    b += other[i]

print(b)
#文字列の入力
n = str(input())

#7が含まれるかどうか判別
if n.find("7") > 0 :
    text = "Yes"
else :
	text = "No"

#表示
print(text)
int = int(input())
i=1
while i<=3:
  dev=int % 10
  if dev == 7:
    print("Yes")
    i=5
  int = int // 10
  i += 1
  if i==3:
    print("No")
l = input()
print("Yes" if l[-1]=='7' else "No")
#!/usr/bin/env python

import sys

N = int(sys.stdin.readline())

mods = []

order = 100
for i in range(3):
    mods.append(N // order)
    N = N - (order * mods[-1])


if 7 in mods:
    print("Yes")
else:
    print("No")
n=input()
n=str(n)
t='nd'
for i in n:
    if i=='7':
        print('Yes')
        t='d'
if t=='nd':print('No')
n=input()
if "7" in n :
    print("YES")
else:
    print("NO")
a=int(input())
while a>0:
    if(a%10==7):
        print('Yes')
        print(a)
        break
    else:a=a//10
if a==0:print('No')
print(a)
n = input()
if n[-1] == 7 or n[-2] == 7 or n[-3]:
	print("Yes")
else:
	print("No")
N = int(input());

if N%10 == 7:
  print("Yes")
elif (N - N%10)%10 == 7:
  print("Yes")
elif (N- N%100) == 700:
  print("Yes") 
else :
  print("No")
ipt = str(input().split())
print(ipt)
if("7" in ipt):
    print("Yes")
else:
    print("No")