// Problem: D. Circle Game // Contest: Codeforces - Codeforces Round 685 (Div. 2) // URL: https://codeforces.com/problemset/problem/1451/D // Memory Limit: 256 MB // Time Limit: 2000 ms // Author: Swapnil Adsul // Institute: Pune Institute of Computer Technology, Pune #include using namespace std; typedef long long int ll; #define int long long #define finout() ios_base::sync_with_stdio(false);cin.tie(NULL);cout.tie(NULL) #include "limits.h" #define find_max *max_element #define Im INT_MAX #define IM INT_MIN #define pie 3.14159265359 #define sz(x) ((ll)(x).size()) #define in(k,a) for(auto &k : a) #define all(a) (a).begin(), (a).end() #define rall(a) (a).rbegin(), (a).rend() #define acc(a) accumulate(all(a),0) #define disp(a) in(k,a){ cout<a(n); rep(i,0,n) cin>>a[i] #define vecd(v) int xyz; cin>>xyz; v.pb(xyz); //////////////////map///////////////////// #define mii map #define mll map #define mss map #define msi map #define mis map #define msl map #define mls map #define ff first #define ss second ///////////////////sorting of map>/////////////////////////// //map >::iterator it; // for (it = mp.begin(); it != mp.end(); ++it) { // sort(it->second.begin(), it->second.end()); // } /////////////////////vector///////////////////////// #define vi vector #define vl vector #define vs vector #define vpl vector> #define pb push_back #define pp pop_back #define sv(arr) sort(arr.begin(),arr.end()) #define rv(arr) reverse(arr.begin(),arr.end()) //std::vector::iterator upper1, upper2; // std :: upper_bound //upper1 = std::upper_bound(v.begin(), v.end(), 35); //upper2 = std::upper_bound(v.begin(), v.end(), 45); //std::cout << "\nupper_bound for element 35 is at position : " // << (upper1 - v.begin()); //std::cout << "\nupper_bound for element 45 is at position : " // << (upper2 - v.begin()); ///////////////////////power (log(n))//////////////////////// double myPow(double x, int n) { double ans = 1.0; long long nn = n; if (nn < 0) nn = -1 * nn; while (nn) { if (nn % 2) { ans = ans * x; nn = nn - 1; } else { x = x * x; nn = nn / 2; } } if (n < 0) ans = (double)(1.0) / (double)(ans); return ans; } //--------------------------------- SET ----------------------------- #define si set #define sl set //#define ss set #define mst set //st.insert() //for(auto i=st.begin();i!=st.end();) // (*it) // st.erase(x) // st.find(*it) //--------------------------------- pair ----------------------------- #define pi pair #define pl pair #define fi first #define se second //--------------------------------- string ----------------------------- #define gl(s) getline(cin,s) #define le(s) s.length() #define str(p,q) s.erase(p,q) // from p index q elements to be removed // to reverse string --> reverse(s.begin(), s.end()) typedef long long ll; //8 typedef long double ld; //12 //--------------------------------- loop ----------------------------- #define f(i,x,n) for(int i = x; i < n; i++) #define rf(i,x,n) for(int i = x; i >= n; i--) #define fr(i,m) for(auto i:m) #define read(a) for(auto& x:a) cin>>x // void print(int &a){for (auto &x : a){cout<>x;}} int lcm(int a, int b) { return a / __gcd(a, b) * b; } int gcd(int a, int b){return b == 0 ? a : gcd(b, a % b);} bool prime(int a){if (a == 1){return 0;}for (int i = 2; i <= round(sqrt(a)); ++i){if (a % i == 0){return 0;}}return 1;} bool isPowerOfTwo(int n) {return ((n==0)?false: (ceil(log2(n)) == floor(log2(n))));} bool isPerfectSquare(ll x) {return ((x>=0)?((ll)sqrt(x)*(ll)sqrt(x)==x):false);} /*----------------------------------------------------------------------------------------------------*/ //------------------------------------------------------------------------- ll expo(ll a, ll b, ll mod) {ll res = 1; while (b > 0) {if (b & 1)res = (res * a) % mod; a = (a * a) % mod; b = b >> 1;} return res;} ll mminvprime(ll a, ll b) {return expo(a, b - 2, b);} ll mod_add(ll a, ll b, ll m) {a = a % m; b = b % m; return (((a + b) % m) + m) % m;} ll mod_mul(ll a, ll b, ll m) {a = a % m; b = b % m; return (((a * b) % m) + m) % m;} ll mod_sub(ll a, ll b, ll m) {a = a % m; b = b % m; return (((a - b) % m) + m) % m;} ll mod_div(ll a, ll b, ll m) {a = a % m; b = b % m; return (mod_mul(a, mminvprime(b, m), m) + m) % m;} //-------------------------------------------------------------------------- // is_sorted(a,a+n) //------------------------------------------------------------- void test(){ int n;cin>>n; int i=1; for(int i=1;i<100007;i++){ if((n)-(i*i)>=0){ int p=(n)-(i*i); if(sqrt(p)*sqrt(p)==p){cout<<"Yes"<>t; while(t--){ test(); } return 0; }