a_,b_ = input().split(" ") a,b = int(a_),int(b_) powAB = a**b powBA = b**a if powAB == powBA: print("Yes") else: print("No")