Question: Create a header file class (Customer) with following private attributes. (5 points) Customer first name Customer last name Customer account Number, Deposit amount. 1. Create
Create a header file class (Customer) with following private attributes. (5 points)
Customer first name
Customer last name
Customer account Number,
Deposit amount.
1. Create public getters and setters for above attributes.
2. Create a constructor with parameters of first name and last Name and account number
3. Create a constructor with first name and last name.
4. Create an object from Customer class (objOne) with first name and last name values. (Come up with your own values)
5. Create a method call printName() in Customer class. This method should print full name for the above created object (objOne).
6. Create a method call registerCustomer() in Customer class.
7. Create another object from Customer class with first name, last name and account number (objTwo). (Come up with your own values).
8. Create a method in customer class call deposit with parameter of type double deposit amount.
9. Ask customer to enter deposit amount when program runs. Store deposit amount Deposit amount variable for second object (objTwo)
10. Then call deposit method for second object (objTwo) with deposit amount. Deposit method should print deposited amount as below in the example.(Names and deposited amount can be any values you created. It doesnt have to be the same values in the example) Example: If First Name is Josh , last name is Zakasi, Deposited amount is 100.0. Print Josh Zakasi deposited $100.0 to his account
Step by Step Solution
There are 3 Steps involved in it
Get step-by-step solutions from verified subject matter experts
