#include using namespace std; int main(){ int A,B; cin >> A >> B; if(B%A==0)cout << B/A << endl; else cout << "NO" << endl; return 0; }