Question: in java pls 2 and 3 29. 4.38 (Factorial) The factorial of a nonnegative integer n is written as n! (pronounced n factorial) and is
in java pls 2 and 3
29. 4.38 (Factorial) The factorial of a nonnegative integer n is written as n! (pronounced "n factorial") and is defined for values of n greater than or equal to 1 as: To! = n(n-1).(n-2).....1 and for the n value 0 as: nl = 1 For example, 5! = 5.4.3.2.1, which is 120. 1. Write an application that reads a nonnegative integer and computes and prints its factorial, 2. Write an application that estimates the value of the mathematical constant e by using the following formula. Allow the user to enter the number of terms to calculate. 1 1 1 1+ + 1! 2! + 3! +... 3. Write an application that computes the value of ex by using the following formula. Allow the user to enter the number of terms to calculate. ex = x + 2! +
Step by Step Solution
There are 3 Steps involved in it
Get step-by-step solutions from verified subject matter experts
