|
|
back to boardWrong answer Posted by Mansur 17 Mar 2009 19:04 В чем ошибка? #include<stdio.h> #include<math.h> void main() { int n,k=0,i=1,j,m; scanf("%d",&n); for(j=1;j<=n;j++) { m=pow(10,j); while (i<m) { if (i*i%m==i) {k++; printf("\n%d %d",i,i*i);} if (i%10==1) i=i+4; else if (i%10==5) i++; else if (i%10==6) i=i+5; } } printf("%d",k); } Re: Wrong answer Posted by kis 19 Mar 2009 10:42 pow(10, 2000.)? //1 ≤ n ≤ 2000 |
|
|