While Loops
2 / 5
Factorial
Input an integer n
.
Compute and print the factorial of n
.
Hint: the factorial of n
is the product of all positive integers up to n
.
For example, if n
is 5, the factorial is 5 * 4 * 3 * 2 * 1 = 120
.