subject
Computers and Technology, 02.12.2019 23:20

Bank accounts

look at the account class account. java and write a main method in a different class to briefly experiment with some instances of the account class.

• using the account class as a base class, write two derived classes called savingsaccount and checkingaccount. a savingsaccount object, in addition to the attributes of an account object, should have an interest variable and a method which adds interest to the account. a checkingaccount object, in addition to the attributes of an account object, should have an overdraft limit variable. ensure that you have overridden methods of the account class as necessary in both derived classes.

• now create a bank class, an object of which contains an array of account objects. accounts in the array could be instances of the account class, the savingsaccount class, or the checkingaccount class. create some test accounts (some of each type).

• the bank class requires a method for opening accounts, and to deposit and withdraw from accounts specified by their account number. account numbers are generated sequentially starting with 101.

hints:

• note that the balance of an account may only be modified through the deposit(double) and withdraw(double) methods.

• the account class should not need to be modified at all. • be sure to test what you have done after each step.

• use bankdemo. java to test your code.

ansver
Answers: 1

Another question on Computers and Technology

question
Computers and Technology, 04.02.2019 21:44
When designers make compromises during the engineering design process the result is often what?
Answers: 1
question
Computers and Technology, 31.01.2019 23:00
The total greenhouse gas emissions generated by people, things, events, or groups are called
Answers: 2
question
Computers and Technology, 28.01.2019 21:12
What is the original authority for copyright laws
Answers: 1
question
Computers and Technology, 27.01.2019 02:57
Which one of the following voltages should never be measured directly with a vom? a. 1200 v b. 500 v c. 800 v d. 100v
Answers: 2
You know the right answer?
Bank accounts

look at the account class account. java and write a main method in a diff...
Questions
question
Computers and Technology, 14.09.2019 12:00
question
Computers and Technology, 14.09.2019 12:00
question
Computers and Technology, 14.09.2019 12:00
question
Mathematics, 14.09.2019 12:50
question
Computers and Technology, 14.09.2019 12:50
Questions on the website: 6713914