Advertisement
amine99

Untitled

Jan 25th, 2018
87
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
C++ 0.32 KB | None | 0 0
  1. #include <bits/stdc++.h>
  2.  
  3. using namespace std;
  4. typedef long long ll;
  5. #define loop(i,b,e) for(int i = b ; i < e ; i++)
  6.  
  7. //Declarations
  8. int n;
  9. ll x;
  10. //END Declarations
  11.  
  12. int main()
  13. {
  14.    cin >> n;
  15.    loop(i,0,n)
  16.    {
  17.       cin >> x;
  18.       puts((int)sqrt(x)*(int)sqrt(x) == x && x != 1 ? "YES" : "NO");
  19.    }
  20. }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement