using namespace std; int a,b,c,d; int main() {
for (d = 1000; d <= 9999; d++) {
for (c = 0; c <= sqrt(9999); c++) {
for (a = 0; a <= 9; a++) {
for (b = 0; b <= 9; b++) {
if ((d == pow(c, 2) && (d == 1000 * a + 100 * a + 10 * b + b) && (a != b))) {
cout<<d<<endl;
}
}
}
}
}
return 0;
}
//暴力也是真暴力
人才