Four patterns emerge from factorial and sum of digits:
Define a base case first. Without it, recursion never stops. For factorial: . For sum of digits: single-digit numbers.
Each call must progress toward the base case. Factorial subtracts . Sum of digits divides by . No progress means infinite recursion.
Trust the recursive call. When writing factorial(n-1), assume it works. Focus on combining that result correctly.
The call stack handles memory. Each call has its own n. You don't track state manually.