Answered step by step
Verified Expert Solution
Link Copied!

Question

1 Approved Answer

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 500 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 10-10, Chapter 10), the class dateType (as designed in this chapters Programming Exercise 2), 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 500 entries.
The program should perform the following operations:
Load the data into the address book from a disk (Ch11_Ex5Data.txt).
Sort the address book by last name.
Search for a person by last name (option 1).
Print the address, phone number, and date of birth (if it exists) of a given person (option 2).
Print the names of the people whose birthdays are in a given month (option 3).
Print the names of all the people between two last names (option 4).
Depending on the users request, print the names of all family members, friends, or business associates (option 5).
Print the entire address book (option 6).
Save the sorted address book to a file (option 7).
Terminate the program (option 9).
An example of the program is shown below:
Enter file name: Ch11_Ex5Data.txt
Welcome to the address book program.
Choose among the following options:
1: To see if a person is in the address book
2: Print the information of a person
3: Print the names of person having birthday in a particular month
4: Print the names of persons between two last names
5: Print the names of persons having a particular status
6: Print the address book
7: Save data
9: Terminate the program
2
Enter the last name of the person: Balto
Brave Balto
Date of Birth: 2-6-1975
Phone Number: 415-782-5555
Person Type: Business
Disney Road
Orlando, Florida -35672
image text in transcribed

Step by Step Solution

There are 3 Steps involved in it

Step: 1

blur-text-image

Get Instant Access to Expert-Tailored Solutions

See step-by-step solutions with expert insights and AI powered tools for academic success

Step: 2

blur-text-image

Step: 3

blur-text-image

Ace Your Homework with AI

Get the answers you need in no time with our AI-driven, step-by-step assistance

Get Started

Recommended Textbook for

Pro Oracle Fusion Applications Installation And Administration

Authors: Tushar Thakker

1st Edition

1484209834, 9781484209837

More Books

Students also viewed these Databases questions

Question

How do linear and nonlinear presentations differ? [LO-1]

Answered: 1 week ago