n = str(eval(input()))



if n[0] == '7' or n[1] == '7' or n[2] == '7':

    print('Yes')

else:

    print('No')
n = list(eval(input()))



for i in n:

    if '7' in n:

        print('Yes')

        break

    else:

        print('No')

        break
n = str(eval(input()))
if n[0] == "7" or n[1] == "7" or n[2] == "7":
    print("Yes")
else:
    print("No")

n = list(eval(input()))
for i in n:
    if "7" in n:
        print("Yes")
        break
    else:
        print("No")
        break

-n = str(eval(input())) -if n[0] == "7" or n[1] == "7" or n[2] == "7": -    print("Yes") -else: -    print("No") +n = list(eval(input())) +for i in n: +    if "7" in n: +        print("Yes") +        break +    else: +        print("No") +        break