import java.util.Scanner; public class A{ public static void main(String[] args){ Scanner s = new Scanner(System.in); int a = Integer.parseInt(s.next()); int b = Integer.parseInt(s.next()); double ans; ans = (double)a / b; if(ans % 1 ==0){ System.out.println((int)ans); } else{ System.out.println("NO"); } } }