Answered step by step
Verified Expert Solution
Link Copied!

Question

1 Approved Answer

Write a program in java to do the following. Assume that at the start of year 1, a person deposits 1000 into a savings account.

Write a program in java to do the following. Assume that at the start of year 1, a person deposits 1000 into a savings account. At the end of the year, the bank adds 5% interest to the amount on deposit, giving 1050. At the end of the second year, the bank adds another 5% of the amount that has been on deposit, making the account 1102.50. This continues for 20 years. Write a program which uses a loop to calculate the year number (1, 2, .., 20) and the account amount for each year. The program should print the year number and the amount at the end of that year for each of the 20 years.

Step by Step Solution

There are 3 Steps involved in it

Step: 1

blur-text-image

Get Instant Access to Expert-Tailored Solutions

See step-by-step solutions with expert insights and AI powered tools for academic success

Step: 2

blur-text-image

Step: 3

blur-text-image

Ace Your Homework with AI

Get the answers you need in no time with our AI-driven, step-by-step assistance

Get Started

Recommended Textbook for

Learn To Program Databases With Visual Basic 6

Authors: John Smiley

1st Edition

1902745035, 978-1902745039

More Books

Students also viewed these Databases questions