#include
unsigned long fun(unsigned long n)
{ unsigned long x=0, s, i; int t;
s=n;
/**********found**********/
i=1;
/**********found**********/
while(s!=0)
{ t=s%10;
if(t%2==0){
/**********found**********/
x=x+t*i; i=i*10;}
s=s/10;
}
return x;
}
main()
{ unsigned long n=-1;
while(n>99999999||n<0)
{ printf("Please input(0
printf("\nThe result is: %ld\n",fun(n));
}
老师,我想问这段程序的
if(t%2==0){
/**********found**********/
x=x+t*i; i=i*10;}
括号为什么会打到i=i*10;这条语句的后面。我想不明白