标签:img log ace ret int while es2017 nod turn
#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\n",i,j); c++; } } if(!c){ printf("No Solution\n"); } } return 0; }
标签:img log ace ret int while es2017 nod turn
原文地址:http://www.cnblogs.com/kimsimple/p/7461007.html