Question
C++ writing classes. It will be to write a program implementing a Management System for a Personal Contact Book. For this assignment, write a class
C++ writing classes.
It will be to write a program implementing a Management System for a Personal Contact Book. For this assignment, write a class called Contact. This class should contain information of a single personal contact. The information includes last name, first name, address, phone, and e-mail address. For now you can store an address as a string. Your class should support the following functions:
1. Constructor that initializes a Contact by accepting all the parameters.
2. Default constructor that initializes everything to default values.
3. Accessor functions for each field.
4. Mutator functions for each field.
5. Input function to solicit the information.
6. Output function to print out the information about the contact to console in a nice format.
7. Any other necessary functions you feel are appropriate.
Make sure the mutator functions accept correct formats of both email and phone number. (i.e. e-mail must be of the form [e-mail-account]@[domain-name].[top-level-domain]. Phone number should be a string of 10 digits) Write a driver program to test you class
Step by Step Solution
There are 3 Steps involved in it
Step: 1
Get Instant Access to Expert-Tailored Solutions
See step-by-step solutions with expert insights and AI powered tools for academic success
Step: 2
Step: 3
Ace Your Homework with AI
Get the answers you need in no time with our AI-driven, step-by-step assistance
Get Started