#include using namespace std; int main() { ios::sync_with_stdio(false); cin.tie(0); int n, z; cin >> n >> z; if (n == 1) { puts(z == 1 ? "No" : "Yes"); } else if (n == 2) { for (int x = 1; x <= z; x++) { for (int y = 1; y <= z; y++) { if (x * x + y * y == z * z) { puts("Yes"); return 0; } } } puts("No"); } else { puts("No"); } return 0; }