1 ask the user for the amount deposited into the account


(Program analysis worksheet)

Write a program that calculates the balance of a savings account at the end of a period of time. It should ask the user for the annual interest rate, the starting balance, and  the number of months that have passed since the account was established. A loop should then iterate once for every month, performing the following:

1) Ask the user for the amount deposited into the account during the month. This amount should be added to the balance.

2) Ask the user for the amount withdrawn from the account during the month. This amount should be subtracted from the balance.

3) Calculate the monthly interest. The monthly interest rate is the annual interest rate divided by 12. Multiply the monthly interest rate by the balance and add the result to the balance.

After the last iteration, the program should display the ending balance, the total amount of deposits, the total amount of withdrawals, and the total interest eared.

Solution Preview :

Prepared by a verified Expert
Basic Computer Science: 1 ask the user for the amount deposited into the account
Reference No:- TGS02477776

Now Priced at $20 (50% Discount)

Recommended (94%)

Rated (4.6/5)