Factorial Machine

The Factorial Machine

Input:

Output: