Question: A) Using the class BankAccount' defined in the assignment 2, modify it according to the fall 1. Remove data member Bank Account Type (Current Account,

 A) Using the class BankAccount' defined in the assignment 2, modify

A) Using the class BankAccount' defined in the assignment 2, modify it according to the fall 1. Remove data member "Bank Account Type (Current Account, Savings Account)" from kAccount dass. 2. Modify the parameterized constructor to take balance as argument. 3. Add copy contractor. B) Create an inheritance hierarchy where "BankAccount" is the base class and "SavingAcco d "Current Account" are derived classes. With the SavingAccount, the Bank pays interest Year to the customer based on the account balance. With the CurrentAccount the Bank s1 JD as charges for each withdraw transaction. 1. Initialise a SavingAccount and Current Account objects with an initial balance 100JD 2. Write the code of 'CalculateInterest' function for the SavingAccount class. It should ca he interest yearly and add it to the balance 3. Write the code of Transaction Charge function for the CurrentAccount class. It should 1 JD from the balance after each withdraws transaction. 4. Create a "FlexyAccount" class that drived from SavingAccount and Current Account. 5. create 'CalculateInterest' function for the FlexyAccount class, knowing that the interes 1% 6 create Transaction Charge function for the FlexyAccount class, knowing that the chan ach withdraw transaction is 0.5 JD. 7 Write the appropriate code for the destructor of each derived class. 8. Write the code of 'PrintBank function for each derived class. A) Using the class BankAccount' defined in the assignment 2, modify it according to the fall 1. Remove data member "Bank Account Type (Current Account, Savings Account)" from kAccount dass. 2. Modify the parameterized constructor to take balance as argument. 3. Add copy contractor. B) Create an inheritance hierarchy where "BankAccount" is the base class and "SavingAcco d "Current Account" are derived classes. With the SavingAccount, the Bank pays interest Year to the customer based on the account balance. With the CurrentAccount the Bank s1 JD as charges for each withdraw transaction. 1. Initialise a SavingAccount and Current Account objects with an initial balance 100JD 2. Write the code of 'CalculateInterest' function for the SavingAccount class. It should ca he interest yearly and add it to the balance 3. Write the code of Transaction Charge function for the CurrentAccount class. It should 1 JD from the balance after each withdraws transaction. 4. Create a "FlexyAccount" class that drived from SavingAccount and Current Account. 5. create 'CalculateInterest' function for the FlexyAccount class, knowing that the interes 1% 6 create Transaction Charge function for the FlexyAccount class, knowing that the chan ach withdraw transaction is 0.5 JD. 7 Write the appropriate code for the destructor of each derived class. 8. Write the code of 'PrintBank function for each derived class

Step by Step Solution

There are 3 Steps involved in it

1 Expert Approved Answer
Step: 1 Unlock blur-text-image
Question Has Been Solved by an Expert!

Get step-by-step solutions from verified subject matter experts

Step: 2 Unlock
Step: 3 Unlock

Students Have Also Explored These Related Finance Questions!