Write a program called Factorial1to14, to compute the factorial of n, for 1≤n≤14. Your output shall look like: The factorial of 1 is 1 The factorial of 2 is 2 ... The factorial of 10 is 3628800
Hints:
Beware of overflow. Use the proper datatype to avoid numeric overflows.
Overflow occurs for Factorial(n+1) if (Integer.MAX_VALUE / Factorial(n)) < (n+1).