A,B = map(int, input().split()) print(B//A if B%A < 1 else 'NO')