사생활 보호 설정
https://gamjia.tistory.com
Updated News
Mini Rooms
답글수 [0]
What Friends Say
한마디로 표현해봐~
1촌평 관리
10872번 팩토리얼
GamJia 2023. 3. 31. 09:14
단계별로 풀어보기 - 재귀 - 1단계
https://www.acmicpc.net/problem/10872
#include <iostream> using namespace std; int factorial(int N) { if(N>1) { return N*factorial(N-1); } else { return 1; } } int main() { int N; cin>>N; cout<<factorial(N); return 0; }