atiq


{ City } dubai
< Country > other
* Profession * student
User No # 28957
Total Questions Posted # 1
Total Answers Posted # 0

Total Answers Posted for My Questions # 2
Total Views for My Questions # 20582

Users Marked my Answers as Correct # 0
Users Marked my Answers as Wrong # 0
Questions / { atiq }
Questions Answers Category Views Company eMail

The factorial of a nonnegative integer n is written n! (pronounced “n factorial”) and is defined as follows: n! = n · (n - 1) · (n - 2) · … · 1 (for values of n greater than to 1) and n! = 1 (for n = 0 or n = 1). For example, 5! = 5 · 4 · 3 · 2 · 1, which is 120. Use while structures in each of the following: a) Write a program that reads a nonnegative integer and computes and prints its factorial. Use the following function prototype to calculate factorial: int myFactorial(int n); b) Write a program that estimates the value of the mathematical constant e by using the formula: Use the following function prototype to calculate e: double myE( ); Hint: Use an accuracy of 10 terms. c) Write a program that computes the value of ex by using the formula Use the following function prototype to calculate e: double myEx(int x);

2 Engineering AllOther 20582




Answers / { atiq }