#include <bits/stdc++.h>
using namespace std;
int main(){
int n;
cin>>n;
int x=sqrt(n);
if (x*x==n){
cout<<"Y"<<endl;
}
else {
cout<<"N"<<endl;
}
}
/**************************************************************
Problem: 2118
User: xiaojingxuan
Language: C++
Result: Accepted
Time:8 ms
Memory:2072 kb
****************************************************************/