Investment Returns
Premium Content - Free Preview
You're writing a program to predict the return on different mutual funds. You start with $10,000 and are given the predicted annual appreciation and a fixed annual fee (as doubles
). Can you calculate the expected amount your money will be worth after 10 years? Keep track of the exact amount, but print the answer rounded to the nearest dollar.
For example, if given 0.08
and 200.0
, then after 1 year your money will be worth 10,000 * 1.08 - 200 = 10600
. Below is what your money will be worth after each year:
End of Free Content Preview. Please Sign in or Sign up to buy premium content.
Comments
thales
Jul 20, 6:21 AMa solution:
my code
Daniel Kozmacs
Apr 15, 9:09 AMDidn't know I'm able to use math.round, without it: my code.