求帮忙看一下我的程序哪里错了?万谢!
#include<stdio.h>int main(void)
{
int m,n,i,number;
int factorsum(int number);
printf("Enter m:");
scanf("%d",m);
printf("Enter n:");
scanf("%d",n);
for(i=m;i<=n;i++){
if(i==factorsum(i));
printf("%d",i);
}
return 0;
}
int factorsum(int number)
{
int a,result;
result=0;
for(a=1;a<number;a++){
if(number/a==0){
result=result+a;
}
}
return result;
}