阶乘

#include <bits/stdc++.h>
using namespace std;
int fc(int s){
	if(s==1){
		return 1;
	}else{
		return s*fc(s-1);
	}
} 

int main(){
	int n;
	cin>>n;
	cout<<fc(n);
	return 0;
}

  

posted @ 2025-03-23 09:28  昵称就是最好的昵称  阅读(4)  评论(0)    收藏  举报