a,b = map(int,input().split()) if a == b: print("Yes") exit() if (a == 2 and b == 4) or (a == 4 and b == 2): print("Yes") exit() print("No")