![]() |
VOOZH | about |
The exp() function in C++ returns the exponential (Euler's number) e (or 2.71828) raised to the given argument.
Syntax for returning exponential e: result=exp()
Parameter: The function can take any value i.e, positive, negative or zero in its parameter and returns result in int, double or float or long double. Return Value: The exp() function returns the value in the range of [0, inf].
Error:
Application: Given below is an example of application of exp() function
exp(x) = 22026.5 22026.5
Time Complexity: O(1)
Auxiliary Space: O(1)
Here is the program to demonstrate the error in exp() function.
exp(x) = inf inf
Time Complexity: O(1)
Auxiliary Space: O(1)
Applications of e (mathematical constant):
Source : Wiki