Create class using static variable to store annual interest

Assignment Help Programming Languages
Reference no: EM1361915

Create class SavingAccount. 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 annual InterestRate divided by 12; this interest should be added to savingsBalance. Provide a static method modifyInterestRate that sets the annualInterestRate to a new value. A SavingAccount object can be only be opened with a minimum of $1,000.00.

Next, write a program to test class SavingsAccount. Instantiate two SavingsAccount objects, saver1, saver2, saver3 with balances of $900.00, $2,000.00 and $3000.00 respectively. Set annualInterestRate to 4%, then calculate the monthly interest and print the new balances for the valid savers. Then set the annualInterestRate to 5%, calculate the next month's interest and print the new balances for the valid savers.

Reference no: EM1361915

Questions Cloud

Explain what strategic actions should the smucker family : Explain What strategic actions should the Smucker family undertake to further improve the company's financial and market performance?
Style of management when andy introduced her : What did Peggy realize about her own style of management when Andy introduced her to the Gift of the Goose and how did she win the support of the plant managers?
Find magnitudes of the tension forces in the first two ropes : find magnitudes of the tension forces in the first two ropes. what is the velocity of the cart when it reaches its greatest y coordinate.
Longevity and quality of life : What is the long-term outlook for this group in terms of longevity and quality of life?
Create class using static variable to store annual interest : Create class SavingAccount. 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.
Compare the additional revenue of microsoft makes : Compare the additional revenue Microsoft makes as it moves from 20 million to 40 million copies of Vista with the additional revenue it makes as it moves
Explain approach the presentation as if you are the hr : Explain Approach the presentation as if you are the HR manager for a company and have a 15 minute time slot in a meeting to update or educate your managers on an important human resources matter.
Using historical daily returns : Using historical daily returns, you estimated the following Index model for ET incorporated: rET = .01% + 1.75 r S&P500
Empowerment for managers and its impact on employees : Show the importance of empowerment for managers and the impact it has on employees - Empowerment for Managers and Its Impact on Employees

Reviews

Write a Review

Programming Languages Questions & Answers

  Characteristics used for biometric user authentication

You have just been promoted to manager of computer security for large enterprise (XYZ Corporation). Your first project as security manager is to estimate principal physical characteristics used for biometric user authentication.

  Program-customer-s names phone numbers in alphabetical order

Load file into parallel arrays and display list of customers' names and phone numbers in alphabetical order.

  Write program to read file having student'' test scores

Write a C++ program that reads a file named "grades.txt" consisting of students' test scores in the range 0-200 (all integer values). (The first number in the file specifies the number of grades it contains.

  Use switch statement to display roman numeral version

Use a switch statement to display the Roman numeral version of that number. Input Validation: Do not accept a number less than 1 or greater than 10.

  Using the irvine32 library functions

Create 32 random points which have (x, y) co-ordinates

  Create program to calculate amount of paint needed

Create a program to calculate the amount of paint needed to cover one side of a house with a sloped roof . Assume tha this house has a rectangular shape with a rectangular window .

  Program to help gymnasium help desk associate

Write a program that helps a gymnasium help desk associate to answer questions about membership cost. The rates are as follows.

  Development of the current strategic potential of airline

Evaluate the organisation's current external and internal strategic position

  Write a paper on memory management

Write a paper on Memory Management

  Ruby program that continuously reads in number

Write down Ruby program that continuously reads in number, x, from screen, and then calculates and displays its: factorial, if x is less than 15.

  Design application that would output payment coupons

Design the application that would output 12 payment coupons for each of the 15 apartments in each of the 20 buildings. Each coupon should contain the building number.

  Design and implement set of classes to model employees

Design and implement a set of classes to model the employees of a hospital: doctor, nurse, administrator, etc. Include methods in each class.

Free Assignment Quote

Assured A++ Grade

Get guaranteed satisfaction & time on delivery in every assignment order you paid with us! We ensure premium quality solution document along with free turntin report!

All rights reserved! Copyrights ©2019-2020 ExpertsMind IT Educational Pvt Ltd