Question: Write a program to calculate the final amount for a monthly compounded interest for a given number of years, given principal amount, and given interest
Write a program to calculate the final amount for a monthly compounded interest for a given number of years, given principal amount, and given interest rate. Use the JOptionPane class to ask the user for the number of years, principal amount, and interest rate as a percentage. Output the final amount to the user using JOptionPane once it is calculated. Use the following formula to calculate the final amount: Final Amount=P(1+r/n)^nt where P is the principal, r is the interest rate as a decimal value, n is the number of compoundings per year (months per year) and t is the number of years.
Step by Step Solution
There are 3 Steps involved in it
Get step-by-step solutions from verified subject matter experts
