Directions: Create a C program that will display the following requirements. Every savings account has an associated interest rate, and annually ( assuming we have an annual rate), the rate is multiplied with the current balance to get the amount earned as interest. The amount is added to the current balance to get the new balance. For example, suppose we have an initial balance of P100,000.00 deposited at an interest rate of 10%. After one year, the savings account earns P10,000.00 (that's 10% of P100,000.00 ). so the new balance would be P110,000.00. After another year it earns P 11,000.00 (10% of P110,000.00) and the balance would be P121,000.00. Another year would make it P133,100.00 ( P121,000.00 + P12,100.00). Write a program that outputs the interest earned and balance of a savings account each year for several years. The program prompts for the following values: 1.) Initial Balance
Directions: Create a C
Every savings account has an associated interest rate, and annually ( assuming we have an annual rate), the rate is multiplied with the current balance to get the amount earned as interest. The amount is added to the current balance to get the new balance.
For example, suppose we have an initial balance of P100,000.00 deposited at an interest rate of 10%. After one year, the savings account earns P10,000.00 (that's 10% of P100,000.00 ). so the new balance would be P110,000.00. After another year it earns P 11,000.00 (10% of P110,000.00) and the balance would be P121,000.00. Another year would make it P133,100.00 ( P121,000.00 + P12,100.00).
Write a program that outputs the interest earned and balance of a savings account each year for several years. The program prompts for the following values:
1.) Initial Balance
2) Interest rate in decimal
3) Year deposited
4) Year to be withdrawn
Step by step
Solved in 4 steps with 1 images