import java.util.*; import java.util.stream.Stream; public class No485 { public static void main(String[] args) { Scanner sc = new Scanner(System.in); int a = sc.nextInt(), b = sc.nextInt(); System.out.println(b % a == 0 ? b / a : "NO"); } }