#include "bits/stdc++.h" using namespace std; #define LL long long #define INF 0x3f3f3f3f3f #define PI acos(-1) #define N 1000000 #define MOD 10 int main() { int n; while(~scanf("%d",&n)) { int c=0,j; for(int i=0;i<=n;i++){ j=sqrt(n-i*i); if(j*j==n-i*i){ if(j<i) break; printf("%d %d ",i,j); c++; } } if(!c){ printf("No Solution "); } } return 0; }