Now you will compute , the product of all positive integers up to . For example, . You could use a loop, but factorial is perfect for recursion because it has natural structure: .
Every factorial depends on a smaller factorial. Before reading on, think about this: when should you stop computing? And why is a stopping point necessary?