a,b=map(int,input().split()) print("NO"if b%a else b//a)