This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| /** | |
| * S&P 500 from 2010 to 2019, the average stock market return for the last 10 years is 11.805% | |
| * This can be different for other indexes. We can make a dictionary of returns and see how others compare to it. | |
| * | |
| * Given a static amount or added over the years we can see how it will look like after x years. | |
| * | |
| * */ | |
| class InvestmentCalculator(val initial: Double, val returnPercentage: Double, val years: Int) { | |
| /* |
OlderNewer