#include <bits/stdc++.h>
using namespace std;

typedef long long ll;
#define REP(i,n) for(int i=0,_n=(int)(n);i<_n;++i)
#define ALL(v) (v).begin(),(v).end()
#define CLR(t,v) memset(t,(v),sizeof(t))
template<class T1,class T2>ostream& operator<<(ostream& os,const pair<T1,T2>&a){return os<<"("<<a.first<<","<<a.second<< ")";}
template<class T>void pv(T a,T b){for(T i=a;i!=b;++i)cout<<(*i)<<" ";cout<<endl;}
template<class T>void chmin(T&a,const T&b){if(a>b)a=b;}
template<class T>void chmax(T&a,const T&b){if(a<b)a=b;}

ll nextLong() { ll x; scanf("%lld", &x); return x;}

int main2() {
  ll S = nextLong();
  ll P = nextLong();

  for (ll a = 1; a * a <= P; a++) {
    if (P % a == 0) {
      ll b = P / a;
      if (a + b == S) {
        return 1;
      }
    }
  }
  return 0;
}

int main() {

  bool ans = main2();
  cout << (ans ? "Yes":"No") << endl;

  return 0;
}
#include <iostream>
#include <bits/stdc++.h>
using namespace std;
int main(void){
    int a,b;
    cin >> a >> b;
    int c;
    c=a+b;
    if(15<=c){
        if(8<=b){
            cout << "1" << endl;
        }
        else if(3<=b){
            cout << "2" << endl;
        }
        else{
            cout << "3" << endl;
        }
    }
    else if(10<=c){
        if(3<=b){
            cout << "2" << endl;
        }
        else{
            cout << "3" << endl;
        }
    }
    else if(3<=c){
        cout << "3" << endl;
    }
    else{
        cout << "4" << endl;
    }
}