0% found this document useful (0 votes)
15 views19 pages

Cs Project

The document is a project report on 'Simple Contact Book' created by students S. Arjun Sarati, A. Vivin Devanidhi, and R. Yohan under the guidance of Mrs. K. Sasirekha. It details the development of a Python program for managing contact details, including functionalities for adding, viewing, searching, and deleting contacts, as well as future enhancements like GUI integration and database support. The report includes acknowledgments, implementation methodology, technologies used, system design, coding examples, and a conclusion highlighting the project's educational value.

Uploaded by

arjunsarati
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as DOCX, PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
15 views19 pages

Cs Project

The document is a project report on 'Simple Contact Book' created by students S. Arjun Sarati, A. Vivin Devanidhi, and R. Yohan under the guidance of Mrs. K. Sasirekha. It details the development of a Python program for managing contact details, including functionalities for adding, viewing, searching, and deleting contacts, as well as future enhancements like GUI integration and database support. The report includes acknowledgments, implementation methodology, technologies used, system design, coding examples, and a conclusion highlighting the project's educational value.

Uploaded by

arjunsarati
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as DOCX, PDF, TXT or read online on Scribd
You are on page 1/ 19

A Project Report On

“SIMPLE CONTACT BOOK”

Submitted By
S.ARJUN SARATI
A.VIVIN DEVANIDHI
R.YOHAN
Class : XI – B

Under the Guidance of


Mrs. K.Sasirekha
PGT(Computer Science)

Department of Computer Science


Vijayanta Senior Secondary School
(AVNL ESTATE, AVADI, CHENNAI –
600 054)
1
Certificate
This is to certify that S ARJUN SARATI , A VIVIN DEVANIDHI , R

YOHAN student of class XI has successfully prepared the report

on the Project entitiled “SIMPLE CONTACT BOOK” under the

guidance of Mrs. SASIREKHA (PGT Computer Science). The

report is the result of her efforts and endeavours. The report is

found worthy of the acceptance as final project report for the

subject Computer Science of class XI .

Date :

Signature of Internal Examiner Signature of

External Examiner

Signature of Principal

2
COMPUTER SCIENCE
INVESTIGATORY PROJECT

BY:
S.ARJUN SARATI

3
A.VIVIN DEVAPRIYAN
R.YOHAN
11B
INDEX

ACKNOWLEDGEMENT 5

PROJECT
DISCRIPTION 6

IMPLEMENTAL
METHANOLOGY 7

TECHNOLOGIES USED
AND REQUIRED 9

SYSTEM DESIGN 10

FUTURE SCOPE 11

CODING 12

OUTPUT 17

4
CONCLUSION 18

REFERENCES 18
ACKNOWLEDGEMENT

We would like to express a deep sense


of thanks & guidance to my project guide
Mrs. Sasirekha Mam for guiding me
immensely through the course of the
project. She always evinced keen interest in
my work. Her constructive advice &
constant motivation have been responsible
for the successful completion of this
project.
Our sincere thanks goes to Dr. S.
Sarada, Our Principal Madam, for her co-
ordination in extending every possible
support for the completion of this project.
We also thanks to my parents for their
motivation & support. We must thanks to
my classmates for their timely help &
support for compilation of this project.
Last but not least, we would like to
thank all those who had helped directly or
indirectly towards the completion of this
project.

5
S.ARJUN SARATI
A.VIVIN DEVANIDHI
R.YOHAN
Class : XI – B

PROJECT DISCRIPTION

In this project “ Simple Contact Book”we have developed a


python program which can to store, manage, and retrieve
contact details, including name, phone number, and email
address. It Add new contacts with validation for phone
numbers. We can view all saved contacts in an organized
format. We can search for a contact using a name. We can
delete an existing contact by name. We can also Store contact
details in a text file for long-term storage.

This project is an easy to use, menu driven application, using


functions, loops, conditional statements, and file handling. Its
especially very useful in schools, collages, restaurants ,etc.

6
It has its application in day to day life too.

IMPLEMENTATION
METHODOLOGY

The implementation is done using the following steps:

1️. User Menu:


 It displays a menu with options like Add, View, Search,
Delete, and Exit.
 It takes the user's choice as input.

2️. Adding a Contact:


 It takes user input (name, phone, email).
 It validates the phone number (exactly 10 digits).
 It saves data in contacts.txt using file handling.

3️. Viewing Contacts:


7
 It reads contacts from the file.
 It displays them in a structured format.

4️. Searching a Contact:


 It reads all saved contacts.
 It searches by name and displays details if found.

5️. Deleting a Contact:


 It reads the contact list.
 It removes the specified contact.
 It saves the updated list back to the file.

6️. Loop & Error Handling:


 While loop keeps the program running until the user
chooses Exit.
 Exception Handling (try-except) is used to handle file-
related errors.

8
TECHNOLOGIES USED
AND
REQUIRED

This project is implemented using:

1.Python : Core programming language


2.File handling : Storing and retrieving contacts
3.Functions : Code modularity and reusability
4. Lists : Storing and processing data
5.Loops : Repeating tasks (menu navigation)
6.Conditional : Decision-making (if-else)
Statements

Software Requirements:
 Python 3.x (latest version recommended)
9
 A text editor (IDLE, VS Code, PyCharm, or Notepad++)

Hardware Requirements:
 A computer with Windows/Linux/macOS
 Minimum 2GB RAM and 100MB free storage

SYSTEM DESIGN

The architecture of the Contact Book system follows a simple


file-based storage model.

USER INPUT

Function
Execution

File
handling

10
Display
results

Data Storage Format (contacts.txt):


The contacts are stored in a text file in CSV format (Comma-
Separated Values).

FUTURE SCOPE

This project can be improved and expanded in various ways:

GUI Interface:
 Convert the text-based menu into a Graphical User
Interface (GUI) using other advanced functions

Database Integration:
 Replace the text file storage with a database (SQLite,
MySQL) for better data management.(Information from
google)

Sorting & Filtering:

11
 Add options to sort contacts alphabetically or filter
contacts based on criteria (e.g., email providers).

Export & Backup:


 Add a feature to export contacts to CSV/Excel.
 Create an automatic backup system.

Mobile App or Web App:


 Convert this into a mobile app using Kivy or a web-
based contact book using Flask/Django.

CODING

# Simple Contact Book

def add_contact():
name = input("Enter Name: ")

# Validate phone number (exactly 10 digits)


while True:
phone = input("Enter Phone Number (10 digits only): ")
if phone.isdigit() and len(phone) == 10:
break
else:

12
print("Invalid phone number! Please enter exactly 10
digits.")

email = input("Enter Email: ")

file = open("contacts.txt", "a") # Open file in append mode


file.write(name + "," + phone + "," + email + "\n")
file.close()

print("Contact added successfully!\n")

def view_contacts():
try:
file = open("contacts.txt", "r") # Open file in read mode
contacts = file.readlines()
file.close()

if len(contacts) == 0:
print("No contacts found!\n")
return

print("\n--- Contact List ---")


for contact in contacts:
data = contact.strip().split(",")

13
print("Name:", data[0], "| Phone:", data[1], "| Email:",
data[2])
print()
except FileNotFoundError:
print("No contacts found!\n")

def search_contact():
search_name = input("Enter the name to search: ").lower()
found = False

try:
file = open("contacts.txt", "r")
contacts = file.readlines()
file.close()

for contact in contacts:


data = contact.strip().split(",")
if data[0].lower() == search_name:
print("\nContact Found:\nName:", data[0], "|
Phone:", data[1], "| Email:", data[2], "\n")
found = True
break

if not found:
14
print("Contact not found!\n")
except FileNotFoundError:
print("No contacts found!\n")

def delete_contact():
"""Deletes a contact by name."""
delete_name = input("Enter the name to delete: ").lower()
contacts = []
deleted = False

try:
file = open("contacts.txt", "r")
contacts = file.readlines()
file.close()

file = open("contacts.txt", "w")


for contact in contacts:
data = contact.strip().split(",")
if data[0].lower() != delete_name:
file.write(contact)
else:
deleted = True
file.close()

15
if deleted:
print("Contact deleted successfully!\n")
else:
print("Contact not found!\n")
except FileNotFoundError:
print("No contacts found!\n")

# Main menu loop


while True:
print("📞 Simple Contact Book")
print("1. Add Contact")
print("2. View Contacts")
print("3. Search Contact")
print("4. Delete Contact")
print("5. Exit")

choice = input("Enter your choice: ")

if choice == "1":
add_contact()
elif choice == "2":

16
view_contacts()
elif choice == "3":
search_contact()
elif choice == "4":
delete_contact()
elif choice == "5":
print("Exiting Contact Book. Goodbye!")
break

else:
print("Invalid choice! Please enter a number between 1-
5.\n")

OUTPUT

17
18
CONCLUSION

The Simple Contact Book is a beginner-friendly Python


project that demonstrates file handling, functions, loops, and
conditional statements in a real-world application.
It is a scalable project that can be enhanced with GUI,
database, and cloud features in the future.

REFERENCES
Code is referred from Class 11 NCERT , Google and Friends.

19

You might also like