e^x, C/C++ Programming

Write a program to calculate e^x using the formula:

e^x = 1 + x/1! + x^2/2! + x^3/3! + ......

Allow the user to enter the integer number x, then do the calculation in a loop (for or while), taking it out ten iterations. For example, if the user entered 2, the program would calculate

e^2 = 1 + 2/1! + 2^2/1! + 2^3/3! + ..... + 2^9/9! + 2^10/10!

Note: Make the factorial calculation a serperate module and call if from main( ).
Posted Date: 4/27/2013 7:32:56 PM | Location : United States







Related Discussions:- e^x, Assignment Help, Ask Question on e^x, Get Answer, Expert's Help, e^x Discussions

Write discussion on e^x
Your posts are moderated
Related Questions
Described the differences among a C++ struct & C++ class? A: The default member & base class access specifies are distinct. It is one of the commonly misunderstood aspects of C+


#quesdifferentiate betweenrelocatable and self relocating program with exampletion..

What is the use of default constructor? - It's a constructor that doesn't accept any parameters. - If there is no user-defined constructor for a class, compiler declares a d

At a shop of marbles, packs of marbles are prepared. Packets are named A, B, C, D, E …….. All packets are kept in a VERTICAL SHELF in random order. Any numbers of packets with thes

exemples of many to many

#padovan string in java   program in java // aakash , suraj , prem sasi kumar kamaraj college program 1 : package test.padovanstring; public class PadovanStrin

how are metric numer change the number of metric

A: In C++, the definition of NULL is 0, thus there is only an aesthetic difference. I prefer to ignore macros, so I employ 0. Another difficulty with NULL is that people sometimes

what is virtual datatype