Question: In C + + no AI please :) Objectives: After performing this lab, the students should be able to - implement class constructors - use
In C no AI please :)
Objectives:
After performing this lab, the students should be able to
implement class constructors
use separate files for programs using classes
This lab is a continuation of lab
Activities
Provide your C source code and screenshots of your program outputs.
Add the following to your class definition for the BankAccount class:
Member variable
o interest: a double variable between and representing the daily interest rate
Member methods
o default constructor: sets the account ID to the account holder name to the empty string, and account balance to
overloaded constructor: sets the account ID to a given ID the account holder name to the given string, and account balance to a given numberaddDailyInterest: calculates the daily interest balance x interest rate and adds it to the balanacePrint: displays the state of the account values of the member variables in an organized format including whether the account is active
Implement all class member functions.
Write a simple drive program that tests the BankAccount class. The driver program should create at least two BankAccount objects using the constructors and invoke each of the new member methods added in this lab. Display the states of the BankAccount object where appropriate. By observing expected outputs from the driver program, you should obtain assurance that your class is implemented correctly.
Use separate files to organize this program:
main.cpp: contains the main program
BankAccount.h: contains the class definition of the BankAccount class
BankAccount.cpp: contains the member function definitions of the BankAccount class
Some Rubric
Criteria
Drive program
pts
The driver
Full
program should
Marks
create at least
two BankAccount
objects using the
constructors
invoke each of
the new member
methods added in
this lab.
Display the
states of the
BankAccount
object where
appropriate.
function
correctly
Use separate files
Use separate files
pts
to organize this
Full
program:
main.cpp:
contains the main
program
BankAccount.h:
contains the class
definition of the
BankAccount
class
BankAccount.cpp:
contains the
member function
definitions of the
BankAccount
class
Step by Step Solution
There are 3 Steps involved in it
1 Expert Approved Answer
Step: 1 Unlock
Question Has Been Solved by an Expert!
Get step-by-step solutions from verified subject matter experts
Step: 2 Unlock
Step: 3 Unlock
