Cashback Offer (20th - 30th September 2020). Get Flat 10% Cashback credited in your account on a minimum transaction of $80. Post Your Question

Question Details Normal
$ 20.00

CIS Java class 355A i lab

Question posted by
Online Tutor Profile
request

Implement an inheritance hierarchy based on the following specifications for Account class,

 

Implement an inheritance hierarchy based on the following specifications for Account class, Checking Account class, and Savings Account class: 

Account class

* Methods:  

o processDeposit ( ) – accepts a single double parameter containing the deposit amount. Updates the balance by adding the deposit amount to the balance.  

o processWithdrawal ( ) – accepts a single double parameter containing the withdrawal amount. Updates the balance by subtracting the withdrawal amount for the balance. Note: For now do not worry about negative balances.  

o calcInterest ( ) – Coded as a double method with an empty body.

*  Attributes:   

o String Account Name  

o Integer Account ID  

o Double balance  

* Constructor 

o Prompt the user and accept input for the Account Name, Account ID and the initial balance.  

The CheckingAcct class which is a derived class of the Account class. 

* Attributes:

o Inherits all the attributes of the Account class.  

o The overDraftFee is double and is populated in the constructor of the CheckingAcct class.  

*  Methods:

o calcInterest () – If the account balance is greater than or equal to 3000.00 an interest rate of 1% or .01 is applied to increase the balance.

* Constructor:

o Prompt the user for the OverDraftFee.  

The SavingsAcct class which is a derived class of the Account class. 

* Attributes:

o Inherits all the attributes of the Account class. 

o  There are no other attributes. 

* Methods: 

o calcInterest ( ) – If the account balance is greater than or equal to 5000.00 an interest rate of 4% or .04 is applied to increase the balance. If the balance is greater than or equal to 3000.00 an interest rate of 3% or .03 is applied to increase the balance. Otherwise use an interest rate of 2%. The new balance is returned to the calling program.  

* Constructor:  

o Inherited from the Account class. (no code needed)   

 Main: 

Prompt the user for the bank name and routing number.  Create at least two account objects (each of a different type).  Process a deposit then withdraw then calculate the interest for each account. Generate the following report:

Bank Name: XXXXXXXX Routing Number: XXXXXX

Account Name: XXXXXX                   Account ID: XXXXXXXXX                 Balance: 9999.99

Account Name: XXXXXX                  Account ID: XXXXXXXXX                  Balance: 9999.99 

 

Available Answers
Other Related Questions

No related question exists

The benefits of buying study notes from CourseMerit

Assurance Of Timely Delivery
We value your patience, and to ensure you always receive your homework help within the promised time, our dedicated team of tutors begins their work as soon as the request arrives.
Best Price In The Market
All the services that are available on our page cost only a nominal amount of money. In fact, the prices are lower than the industry standards. You can always expect value for money from us.
Uninterrupted 24/7 Support
Our customer support wing remains online 24x7 to provide you seamless assistance. Also, when you post a query or a request here, you can expect an immediate response from our side.
closebutton
Only 45 characters allowed.
closebutton

$ 629.35