subject

Create class SavingsAccount. Use a static variable annualInterestRate to store the annual interest rate for all account holders. Each object of the class contains a private instance variable savingsBalance indicating the amount the saver currently has on deposit. Provide method calculateMonthlyInterest to calculate the monthly interest by multiplying the savingsBalance by annualInterestRate divided by 12- this interest should be added to savingsBalance. Provide a static method setInterestRate that sets the annualInterestRate to a new value. There should also be a method setSavingsBalance to set the initial savings balance for a new saver or you can do it through a constructor. Write a program to test class SavingsAccount. Instantiate two SavingsAccount objects, saver1 and saver2, with balances of $2000.00 and $3000.00, respectively. Set annualInterestRate to 4%, then calculate the monthly interest for each 12 months and print the new balances for both savers. Next, set the annualInterestRate to 5%, calculate the next month's interest and print the new balances for both savers. If you run this java file right now, it only prints out the amount for 1 month. How can you make my program so that it prints the amount for 13 months?It should print outMonth 1: 2006.67Month 2: 2013.36Month 3: 2020.07Month 4: 2026.80etc. after 12 month, change the rate to be 5 percent

ansver
Answers: 3

Another question on Computers and Technology

question
Computers and Technology, 23.06.2019 13:30
Select the correct answer from each drop-down menu. which types of computer networks are bigger as well as smaller than a man? a man is a network of computers that covers an area bigger than a , but smaller than a .
Answers: 1
question
Computers and Technology, 24.06.2019 20:30
Where is permanent data in the computer stored whenever gym starts his laptop he sees some commands in numbers appearing on the screen these instructions are being preceded by the control unit in
Answers: 1
question
Computers and Technology, 25.06.2019 08:00
What are good colleges to apply to if you got like a 2.5 as a gpa? already got a call back from gcu at least its a start rt
Answers: 2
question
Computers and Technology, 25.06.2019 08:10
What is the requirement for self-contained recovery devices
Answers: 1
You know the right answer?
Create class SavingsAccount. Use a static variable annualInterestRate to store the annual interest r...
Questions
question
Mathematics, 18.10.2020 06:01
question
Mathematics, 18.10.2020 06:01
question
Mathematics, 18.10.2020 06:01
question
Mathematics, 18.10.2020 06:01
question
Chemistry, 18.10.2020 06:01
question
Mathematics, 18.10.2020 06:01
Questions on the website: 13722360