subject

copy the files accountdriver. java (code listing 10.1) and bankaccount. java(code listing 10.2) from the student cd or as directed by your instructor. bankaccount. java is complete and will not need to be modified.

create a new class called checkingaccount that extends bankaccount.

it should contain a static constant fee that represents the cost of clearing one

check. set it equal to 15 cents.

write a constructor that takes a name and an initial amount as parameters. it

should call the constructor for the superclass. it should initializeaccountnumber to be the current value in accountnumber concatenated with –10 (all checking accounts at this bank are identified by the extension –10). there can be only one checking account for each account number. remember since accountnumber is a private member in bankaccount, it must be changed through a mutator method.

write a new instance method, withdraw, that overrides the withdraw method in the superclass. this method should take the amount to withdraw, add to it the fee for check clearing, and call the withdraw method from the superclass. remember that to override the method, it must have the same method heading. notice that the withdraw method from the superclass returns true or falsedepending if it was able to complete the withdrawal or not. the method that overrides it must also return the same true or false that was returned from the call to the withdraw method from the superclass.

compile and debug this class.

task #2 creating a second subclass

create a new class called savingsaccount that extends bankaccount.

it should contain an instance variable called rate that represents the annual

interest rate. set it equal to 2.5%.

ansver
Answers: 1

Another question on Computers and Technology

question
Computers and Technology, 23.06.2019 02:30
How to launch an app: steps to be successful? launching an app is a great idea, but it’s not that easy as we supposed to think. the majority of mobile applications don’t generate revenue because companies aren’t ready to be competitive. referring to our experience in successfully building and launching apps we hope to you omit these difficulties. we are going to talk about ideas, marketing, testing your product, its development, distribution and support. you will learn 8 product launch stages to succeed.
Answers: 1
question
Computers and Technology, 23.06.2019 03:00
State 7 common key's for every keyboard
Answers: 1
question
Computers and Technology, 23.06.2019 06:30
To become an audio technician, the most successful tactics might include the following. (select all that apply). learning how to persuade other people gaining different types of experience in audio technology learning as much as possible about art history establishing a reputation as a reliable professional
Answers: 1
question
Computers and Technology, 24.06.2019 09:00
Why might you chose to crest a function resume
Answers: 1
You know the right answer?
copy the files accountdriver. java (code listing 10.1) and bankaccount. java(code listing 10.2) from...
Questions
question
Mathematics, 28.09.2021 18:10
question
English, 28.09.2021 18:10
question
English, 28.09.2021 18:10
question
English, 28.09.2021 18:10
Questions on the website: 13722363