#include<stdio.h>
int main()
{
long long int jiechen_(int x);
int x,m;
printf("请输入整数x:");
scanf("%d",&x);
m=jiechen_(x);
printf("x!的值为:%d\n",m);
return 0;
}
long long int jiechen_(int x)
{
long long int z;
if(x<0)printf("error!错误");
else if(x==0||x==1)z=1;
else
z=x*jiechen_(x-1);
return(z);
}