Project Report: Library Management
System
Title Page
Project Title: Library Management System using Python
Student Name: Aayansh Pratap
Roll No: 2
Class: XII-D
School Name: K.R. Mangalam Vaishali
Academic Year: 2025–26
Subject: Informatics Practices (IP)
Teacher’s Name: Mr. Nitin Mathur
Certificate
This is to certify that Aayansh Pratap of Class XII-D, Roll No. 2, has successfully completed
the Informatics Practices project titled “Library Management System using Python”
during the academic session 2025–26 under my guidance.
The project is his original work and is in accordance with the CBSE guidelines.
Teacher’s Signature: ___________
Principal’s Signature: ___________
Acknowledgement
I would like to express my heartfelt gratitude to my teacher Mr. Nitin Mathur for his
constant guidance and motivation throughout the project.
I am thankful to my parents and friends for their support and encouragement.
Finally, I thank the Almighty for giving me the strength to complete this project successfully.
Index
1. Introduction
2. Objectives
3. Tools & Technologies Used
4. Software and Hardware Requirements
5. Project Description
6. Modules of the Project
o Data Entry
o Book Search & Availability
o Issue & Return Module
o Fine Calculation
o Report Generation
7. Database Design (CSV/Database)
8. Sample Data
9. Source Code (Screenshots & Explanation)
10. Sample Outputs (with Screenshots)
11. Advantages of the Project
12. Limitations
13. Future Scope
14. Conclusion
15. Bibliography
1. Introduction
A Library Management System (LMS) is designed to automate the process of managing
books in a library. Traditionally, libraries maintained registers to record book details, issues,
returns, and fines. This manual method was time-consuming and error-prone.
This project leverages Python programming and CSV file/database storage to build an
efficient system that stores book records, tracks borrowing activities, calculates fines, and
generates useful reports.
2. Objectives
To build a digital system for managing books in a library.
To allow easy entry, deletion, and updating of book records.
To provide search functionality (by book title, author, ISBN).
To maintain details of book issue and return.
To calculate fines automatically for late returns.
To generate useful reports (books available, most issued books, students with fines,
etc.).
To reduce manual workload and improve accuracy.
3. Tools & Technologies Used
Language: Python 3.x
Libraries:
o pandas (data handling)
o csv (file storage)
o datetime (date handling for issue/return)
o matplotlib (optional, for visualization)
o tkinter (optional, for GUI interface)
Data Format: CSV file (books.csv, students.csv, transactions.csv)
IDE: IDLE / VS Code / PyCharm
4. Software and Hardware Requirements
Software:
Python 3.x installed
Libraries: pandas, matplotlib
Text editor (VS Code / PyCharm / IDLE)
Hardware:
A system with at least 2GB RAM
Windows/Linux operating system
Minimum 500 MB free storage
5. Project Description
The project is divided into three major parts:
1. Data Entry Module – Allows adding new books, removing outdated books, and
updating book details.
2. Transaction Module – Handles issue/return of books and calculates fines.
3. Search & Reports Module – Provides search options and generates reports like
available books, most issued books, etc.
6. Modules of the Project
(a) Data Entry Module
Add a new book with details: Book ID, Title, Author, Publisher, Year, Availability.
Delete a book if not available.
Update book details when required.
(b) Book Search & Availability Module
Search books by title, author, or book ID.
Check availability status.
(c) Issue & Return Module
Record issue date and due date.
Mark return and update availability.
(d) Fine Calculation
Fines are calculated automatically based on the number of late days.
Example: ₹2 per day after due date.
(e) Report Generation
Generate lists of:
o Available books
o Issued books
o Students with overdue books/fines
o Top 5 most issued books
7. Database Design
Sample Tables (stored in CSV files):
books.csv
BookID, Title, Author, Publisher, Year, Available
101, Python Basics, Sumita Arora, BPB, 2020, Yes
102, Data Structures, A Sharma, Pearson, 2019, Yes
103, Machine Learning, Andrew Ng, McGraw, 2021, No
104, Chemistry XII, NCERT, NCERT, 2023, Yes
105, Physics XII, NCERT, NCERT, 2023, No
students.csv
RollNo, Name, Class, Section
1, Aditi, 12, D
2, Aarav, 12, D
3, Ananya, 12, D
4, Rohan, 12, D
transactions.csv
TransactionID, RollNo, BookID, IssueDate, DueDate, ReturnDate, Fine
1, 1, 101, 2025-07-01, 2025-07-15, 2025-07-14, 0
2, 3, 102, 2025-07-05, 2025-07-19, 2025-07-25, 12
8. Sample Data (Expanded Example)
Include at least 20–25 books and 10–15 student entries in your file for realism.
9. Source Code (Simplified)
import pandas as pd
import csv
from datetime import datetime, timedelta
# Add a new book
def add_book(bookid, title, author, publisher, year):
with open("books.csv", "a", newline="") as f:
writer = csv.writer(f)
writer.writerow([bookid, title, author, publisher, year, "Yes"])
# Search book
def search_book(title):
df = pd.read_csv("books.csv")
result = df[df["Title"].str.contains(title, case=False)]
return result
# Issue book
def issue_book(rollno, bookid):
issue_date = datetime.now().date()
due_date = issue_date + timedelta(days=14)
with open("transactions.csv", "a", newline="") as f:
writer = csv.writer(f)
writer.writerow([len(open("transactions.csv").readlines()), rollno,
bookid, issue_date, due_date, "", 0])
print("Book Issued Successfully!")
# Return book
def return_book(trans_id):
df = pd.read_csv("transactions.csv")
df.loc[df["TransactionID"]==trans_id, "ReturnDate"] =
datetime.now().date()
# Fine calculation
df["Fine"] = df.apply(lambda row: max(0, (datetime.now().date() -
datetime.strptime(row["DueDate"], "%Y-%m-%d").date()).days * 2) if
pd.isna(row["ReturnDate"])==False else row["Fine"], axis=1)
df.to_csv("transactions.csv", index=False)
10. Sample Outputs
Search Result (when searching “Python”):
BookID | Title | Author | Available
101 | Python Basics | Sumita Arora | Yes
Report Example:
“Most Issued Books – Python Basics, Chemistry XII, Physics XII”
(You can attach graphs like bar charts of issued books count, pie chart of availability, etc.)
11. Advantages of the Project
Eliminates manual work.
Easy to search and issue books.
Reduces errors and maintains accuracy.
Fine calculation is automatic.
Useful reports can be generated.
12. Limitations
Data stored in CSV files (less secure).
Limited to single-user access.
GUI is optional, default system is text-based.
13. Future Scope
Can be integrated with SQL databases (MySQL).
Can provide online access via web or mobile app.
Barcode/QR code integration for books.
Advanced analytics on most read books.
14. Conclusion
The Library Management System developed in Python is a simple, efficient, and useful
project for school and college libraries. It automates key functions like book management,
issue/return handling, and fine calculation. Though currently file-based, it can be extended
into a full-scale library ERP system in the future.
15. Bibliography
Python Documentation – https://docs.python.org
GeeksforGeeks – https://geeksforgeeks.org
W3Schools Python Tutorials – https://www.w3schools.com/python
CBSE Informatics Practices Syllabus