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