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')