Question: CreditAccount.h / cpp 2 0 points Create this class that publicly derives from BaseAccount. Add a private int data member for the amount spent so

CreditAccount.h/cpp 20 points
Create this class that publicly derives from BaseAccount. Add a private int data member for the amount spent so far to be able to compare to the constant spending limit of 40. This amount should be cumulative, so each withdraw adds to this similarly to the balance. Override the Withdraw function to enforce these rules:
Credit accounts have a spending $40 limit and charge a $5000 fee if you go over that spending limit.
When this fee is applied there should be a message informing the user this happened.

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 Programming Questions!