getE()
From Hack Wars Wiki
| Information for free function getE() | |
| Function | getE() |
| API | Challenge |
| Description | Returns the mathematical constant e in the form of a float. For a better explanation of e, see ln(). |
Example
If you were given by the challenge, respectively the values of principal amount, rate of growth(10% to make life easier), and number of years of growth (let's say 20 years until we get exponents) and told to find the resulting amount, this would be the script:
float principal = getInputFloat; float e = getE(); float a = principal*e*e; setOutputFloat(a); |
