Question#1: Create a Customer class that includes fields for last name, first name, and postal code.
Include a default constructor that initializes last name and first name to “XXX” and zip code to “00000” if no arguments are supplied.
Check whether the zip code is five digits or not
Include a display function
Write a main() function that instantiates and displays two Customer objects: one that uses the default values, and one for which you supply your own values
Save the file as Customer.cpp
Question#2: Create a class named SavingsAccount. Provide fields for the customer (use the Customer class from the previous Exercise), account number, balance, and interest rate.
Provide two constructors. One requires a customer and sets each numeric field to 0; the other requires a customer and an account number and sets the account’s opening balance to JD100 at 3% interest.
Check whether the account number is 9 digits or not.
Include a function that displays an account’s data fields.
Write a main() function that instantiates one SavingsAccount object of each type and displays their values.
Save the file as SavingsAccount.cpp
Question#1: Create a Customer class that includes fields for last name, first name, and postal code.
1. Include a default constructor that initializes last name and first name to “XXX” and zip code to “00000” if no arguments are supplied.
2. Check whether the zip code is five digits or not.
3. Include a display function.
4. Write a main() function that instantiates and displays two Customer objects:
a. one that uses the default values,
b. and one for which you supply your own values
Save the file as Customer.cpp
Question#1: Create a Customer class that includes fields for last name, first name, and postal code.
1. Include a default constructor that initializes last name and first name to “XXX” and zip code to “00000” if no arguments are supplied.
2. Check whether the zip code is five digits or not.
3. Include a display function.
4. Write a main() function that instantiates and displays two Customer objects:
a. one that uses the default values,
b. and one for which you supply your own values