import sys input = lambda: sys.stdin.readline().rstrip() # ----------------------- # s = input() print('Yes' if '4' <= s[0] <= '5' else 'No')