s = int(input())
t = int(input())
if s > 4 and t > 2:
    print("YES")
else:
    print("NO")