Question: The monthly payment for a given loan pays the principal and the interest. The monthly interest is computed by multiplying the monthly interest rate and

The monthly payment for a given loan pays the principal and the interest. The monthly interest is computed by multiplying the monthly interest rate and the balance (the remaining principal). The principal paid for the month is therefore the monthly payment minus the monthly interest. Write a program that lets the user enter the loan amount, number of years, and interest rate and displays the amortization schedule for the loan. Here is a sample run:

Loan Amount: 10000 JEnter Number of Years: 1 -Enter Annual Interest Rate:

7 PEnter Monthly Payment: 865.26 Total Payment: 10383.21 Payment# Interest Principal Balance

Loan Amount: 10000 JEnter Number of Years: 1 -Enter Annual Interest Rate: 7 PEnter Monthly Payment: 865.26 Total Payment: 10383.21 Payment# Interest Principal Balance 806.93 811.64 58.33 9193.07 8381.43 2 53.62 11 10.0 855.26 860.27 0.01 12 5.01 860.25 The balance after the last payment may not be zero. If so, the last payment should be the normal monthly payment plus the final balance. Hint. Write a loop to display the table. Since the monthly payment is the same for each month, it should be computed before the loop. The balance is initially the loan amount. For each iteration in the loop, compute the interest and principal, and update the balance. The loop may look like this: for (i = 1; i

Step by Step Solution

3.50 Rating (163 Votes )

There are 3 Steps involved in it

1 Expert Approved Answer
Step: 1 Unlock

Program plan Enter the loan amount number of years and interest rate from the user Cal... View full answer

blur-text-image
Question Has Been Solved by an Expert!

Get step-by-step solutions from verified subject matter experts

Step: 2 Unlock
Step: 3 Unlock

Students Have Also Explored These Related Java Programming Questions!