x=int(input())
if x<30:
    print("No")
else:
    print("Yes") x=int(input()) x int(input()) int input() input if x<30:
    print("No")
else:
    print("Yes") x<30 x 30 print("No") print "No" print("Yes") print "Yes" x=int(input()) int(input()) x
x=int(input())
if x<30:
    print("No")
else:
    print("Yes")