a,b = (int(x) for x in input().split()) if ab: print("NO") print(a-b+1) if a==b: print("NO") print(1)