Using classes, design an address book. Each contact in the address book must be able to store
Question:
Using classes, design an address book. Each contact in the address book must be able to store the following information:
- Full Name
- Address
- Birth Date
- Phone Number
To do so, you are going to create two classes. The first class, called Contact, will store information for 1 contact. This class should have attributes that can store information for the data mentioned above, as well as a means of accessing/modifying attribute data (i.e., getters and setters).
Next, you are going to create another class called Contact Directory, which will store a collection of Contact objects via an array or vector(your choice). This class should support the following operations:
- Add a New Contact
- Search the Directory by Name (return the contact object back to where its called).
- Display All Contacts (Only display Contact Names).
Once you are finished designing the class, create a Contact Directory object and add the following people to the directory:
- Brad Pitt
- Sally Fields
- Marilyn Monroe
- Timothee Chalamet
- Evan Peters
Note that you may be creative with the rest of the information(address, age, phone number). Call the appropriate operator to output the Contact Directory.
Compress your solution to a ZIP folder and upload it as your answer to your question. Be sure to include a header comment above each file your create stating your name and description of the contents of the file(like you do in the programming assignments).