Wrong Answer
/in/foo.c: In function 'main': /in/foo.c:7:2: warning: this 'if' clause does not guard... [-Wmisleading-indentation] if(a>0) ^~ /in/foo.c:12:3: note: ...this statement, but the latter is misleadingly indented as if it is guarded by the 'if' printf("%u\n",b); ^~~~~~
代码
#include<stdio.h>
int main()
{
int a,b,i;
b=1;
scanf("%u",&a);
if(a>0)
for(i=1;i<=a;i++)
{
b=b*i;
}
printf("%u\n",b);
return 0;
}