Question: Using classes, design an online address book to keep track of the names, addresses, phone numbers, and dates of birth of family members, close friends,
Using classes, design an online address book to keep track of the names, addresses, phone numbers, and dates of birth of family members, close friends, and certain business associates. Your program should be able to handle a maximum of entries.
Define a class addressType that can store a street address, city, state, and ZIP code. Use the appropriate functions to print and store the address. Also, use constructors to automatically initialize the member variables.
Define a class extPersonType using the class personType as defined in Example Chapter the class dateType as designed in this chapters Programming Exercise and the class addressType. Add a member variable to this class to classify the person as a family member, friend, or business associate. Also, add a member variable to store the phone number. Add or override the functions to print and store the appropriate information. Use constructors to automatically initialize the member variables.
Define the class addressBookType using the previously defined classes. An object of the type addressBookType should be able to process a maximum of entries.
The program should perform the following operations:
Load the data into the address book from a disk ChExData.txt
Sort the address book by last name.
Search for a person by last name option
Print the address, phone number, and date of birth if it exists of a given person option
Print the names of the people whose birthdays are in a given month option
Print the names of all the people between two last names option
Depending on the users request, print the names of all family members, friends, or business associates option
Print the entire address book option
Save the sorted address book to a file option
Terminate the program option
An example of the program is shown below:
Enter file name: ChExData.txt
Welcome to the address book program.
Choose among the following options:
: To see if a person is in the address book
: Print the information of a person
: Print the names of person having birthday in a particular month
: Print the names of persons between two last names
: Print the names of persons having a particular status
: Print the address book
: Save data
: Terminate the program
Enter the last name of the person: Balto
Brave Balto
Date of Birth:
Phone Number:
Person Type: Business
Disney Road
Orlando, Florida
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
