Lesson 9: Real-World Project - A Simple Contact Management System
Introduction
Welcome to the hands-on project for Week 4! In this week's project, we will be implementing a simple Contact Management System (CMS) for 24/7 Teach. This CMS will give you practical experience working with advanced data structures like Hash Tables, Trees, and Graphs. You will be using these data structures to store, retrieve, and manage a list of contacts.
Objectives
By the end of this project, you will be able to:
Implement a Hash Table to store contact information.
Use a Binary Search Tree to maintain a sorted list of contacts.
Utilize a Graph to represent the social network of your contacts.
Tools & Technologies
Any high-level programming language (Java, Python, JavaScript, etc.)
Git for version control
Project Requirements
Part 1: Implement a Hash Table for Contact Storage
Design a Hash Table to store individual contact information with the following fields:
Name
Email
Phone Number
Implement Functions:
addContact()
: To add a new contact.getContact()
: To retrieve a contact by name.deleteContact()
: To delete a contact.
Real-World Application: Hash Tables are often used for quick data retrieval in databases.
Part 2: Implement a Binary Search Tree for Sorted Contact List
Design a Binary Search Tree (BST) to keep the contacts sorted by their names.
Implement Functions:
insert()
: To insert a new contact into the BST.search()
: To find if a contact exists.inOrderTraversal()
: To display the sorted list of contacts.
Real-World Application: Many database systems use variants of BST for efficient sorting and retrieval.
Part 3: Implement a Graph to Store Social Network
Design a Graph where each node represents a contact and edges represent friendships between them.
Implement Functions:
addFriendship()
: To add an edge between two contacts.getFriends()
: To list all friends of a contact.recommendFriends()
: To suggest new friends to a contact based on mutual friendships.
Real-World Application: Social networking sites like Facebook and LinkedIn use graph structures to represent user relationships.
Deliverables
Well-commented source code for all the data structures and functionalities.
A
README.md
file explaining your code structure, logic, and how to run the project.Document any challenges you faced and how you overcame them.
Submission Deadline
You have one week to complete this project. Please make sure to push your final code to your GitHub repository and submit the link through the course platform.
Good luck, and have fun building your Contact Management System!
It's time to test our understanding and engage in an in-depth project
Evaluation Metrics
Correctness: Does the code correctly implement the data structures and fulfill the project requirements?
Code Quality: Is the code readable, well-commented, and follows standard coding guidelines?
User Experience: How intuitive is the interaction with the system? Are errors handled gracefully?
Documentation: Is the
README.md
file clear, and does it explain the code and how to run it?Bonus: Have you implemented any additional features, like a user interface or additional functionalities, like editing existing contacts?
Reflection:
After completing the project, take a moment to reflect on what you've learned. What did you find challenging? What topics intrigue you the most? The world of web development is vast, and this is just the beginning!
Participate in the Group Discussion:
Please answer the discussion question in the comment section below.
How would you optimize the performance of the Contact Management System for a large dataset? Discuss the advantages and trade-offs of different advanced data structures for each functionality in the CMS.