求阶乘
#include<stdio.h>
int main()
{
int a=0;
int s=1;
int i=0;
scanf("%d",&a);
for(i=1;i<=a;i++)
{
s=s*i;
}
printf("%d的阶乘为%d\n",a,s);
return 0;
}
标签:return,int,scanf,之路求,之路,阶乘,main From: https://blog.51cto.com/u_16248324/7569915
求阶乘
#include<stdio.h>
int main()
{
int a=0;
int s=1;
int i=0;
scanf("%d",&a);
for(i=1;i<=a;i++)
{
s=s*i;
}
printf("%d的阶乘为%d\n",a,s);
return 0;
}
标签:return,int,scanf,之路求,之路,阶乘,main From: https://blog.51cto.com/u_16248324/7569915