[Java] 재귀 호출 - 팩토리얼 구하기 static int factorial(int n) { if (n > 1) return n * factorial(n - 1); else return 1; } Java 2024.07.03