n = input().split() a = int(n[0]) b = int(n[1]) x = b/a if x % 1 == 0: print(x) else: print("NO")