题解 | #日期类#
对称平方数1
http://www.nowcoder.com/practice/a84d46d5321f4e20931cb725e6c74fad
include <stdio.h>
include <math.h>
int res(int n)
{
int res = 0;
while(n!=0)
{
res = n % 10 + res * 10;
n /= 10;
}
return res;
}
main()
{
int a;
for ( a = 0; a < 257; a++ )
{
if ( a * a == res ( a * a ) )
{
printf ( "%d\n", a );
}
}
}