Answered step by step
Verified Expert Solution
Link Copied!

Question

1 Approved Answer

answer in C++ show steps DO NOT EDIT MAIN NOT EDITABLE 37.1 LAB: BankAccount class Given main0. define the BankAocount class (in files BankAccount hand

answer in C++ show steps DO NOT EDIT MAIN NOT EDITABLE
image text in transcribed
image text in transcribed
image text in transcribed
image text in transcribed
37.1 LAB: BankAccount class Given main0. define the BankAocount class (in files BankAccount hand BankAccount.cpp) that manages checking and savings accounts The class has three private data members - customer name (string) - savings account balance (double) - checking occount batance (double) Implement the following constructor and public member functions as listed below - BankAccount(string newName, double amt1, double amt2) - set the customer name to parameter newName, set the checking account balance to parameter amt1 and set the savings account balance to pararneser amt2. (amt stands for amount) - void SetName(string newName) - set the customer name to parameter newName - string GetNamef) - return the customer name - void SetChecking(double amt) - set the checking account balance to parameter amt - double GetChecking0 - return the checking account balance - void SetSavings(double amt) - set the savings account balance to parameter amt - double GetSavings 0 - return the savings account balance - void DepositChecking(double amt) - add parameter aimt to the cheoking account balance (only if positive) - void DepositSavings(double amt) - add parameter arnt to the savings account belance (only if positive) - void Withdramchecking(double amt) - subtract parameter amt from the checking account bolance (only if positive) - void WithdrawSovings(double amt) - subtract parameser amt from the savings account balance (coily if positive) - void Transfer ToSavings(double amt) - subtract parameter amt from the checking account balance and add to the savings account. balance (only if positive) Current file: BankAccount.h * Load defouit template- Run your program as often as you'd like, before submitting for grading. Below, type any needed input values in the first box, then click Run program and observe the program's output in the second box. 1 \#include h " using namespace std; // TODO: Define public member functions 1 Run your program as often as youdd like, before submitting for grading Beiow, type any needed: input values in the first box, then click Run program and observe the program's output in the second box: Flle is marked as read only Current file: main.cpp *

Step by Step Solution

There are 3 Steps involved in it

Step: 1

blur-text-image

Get Instant Access to Expert-Tailored Solutions

See step-by-step solutions with expert insights and AI powered tools for academic success

Step: 2

blur-text-image

Step: 3

blur-text-image

Ace Your Homework with AI

Get the answers you need in no time with our AI-driven, step-by-step assistance

Get Started

Recommended Textbook for

Professional Visual Basic 6 Databases

Authors: Charles Williams

1st Edition

1861002025, 978-1861002020

More Books

Students also viewed these Databases questions

Question

What is quality of work life ?

Answered: 1 week ago

Question

What is meant by Career Planning and development ?

Answered: 1 week ago

Question

What are Fringe Benefits ? List out some.

Answered: 1 week ago