tiying @ 2023-09-07 15:51:00
#include<stdio.h>
int m[10000],mh=0,c=0,n,i;
int main(){
m[0] = 1;
scanf("%d",&n);
while(n>1){
i=0;
while(c!=0 || i<=mh){
m[i] =m[i]*n+c;
c = m[i]/10;
m[i] %= 10;
if(i>mh) mh = i;
i++;
}
n--;
}
for(;mh>=0;mh--) printf("%d",m[mh]);
return 0;
}
by Darling_ZX @ 2023-09-07 16:04:50
我这边测的Windows下答案也不对吧
by gdxmd1 @ 2023-10-25 08:49:21
对,Windows下答案也不对