#include using ll = long long; using namespace std; int main() { ios::sync_with_stdio(false); cin.tie(nullptr); int n, z; cin >> n >> z; if (n == 1) { cout << (z > 1 ? "Yes" : "No") << "\n"; return 0; } else if (n == 2) { if (z % 2 == 0) cout << "No" << "\n"; else { for (int m = 2; m < z; m += 2) { for (int n = 1; n < m; n += 2) { if (m * m + n * n == z * z) { cout << "Yes" << "\n"; return 0; } } } cout << "No" << "\n"; } } else cout << "No" << "\n"; return 0; }