10,000 at 5% for 20 years, monthly compounding
With principal 10000, rate 5, and 20 years, the final value is about 27,126 — the interest portion alone is about 17,126, more than the original deposit.
Example input and output | Input | Value |
| principal | 10000 |
| annualRate | 5 |
| years | 20 |
| compounding | monthly |
| Result | ≈ 27,126 · 17,126 of it interest |
Saving 200 a month for 10 years at 6%
With no initial balance, a 200 monthly contribution, and monthly compounding, the projection reaches about 32,829 — of which 24,000 came from the contributions themselves and about 8,829 from compounding.
Example input and output | Input | Value |
| principal | 0 |
| annualRate | 6 |
| years | 10 |
| monthlyContribution | 200 |
| compounding | monthly |
| Result | ≈ 32,829 final value |