Miniproject
Miniproject
Table of content
Table of content....................................................................................................................... 2
ACKNOWLEDGEMENT .............................................................................................................. 4
ABSTRACT .............................................................................................................................. 5
INTRODUCTION....................................................................................................................... 5
1.2 BACKGROUND OF PROJECT .............................................................................................. 7
1.3 Operation environment ..................................................................................................... 8
1. Hardware Requirements ............................................................................................... 8
2. Software Requirements ................................................................................................ 8
SYSTEM ANALYSIS ................................................................................................................... 9
2.1 SOFTWARE REQUIREMENT SPECIFICATION ......................................................................... 9
GENERAL DESCRIPTION ..................................................................................................... 9
2.1.1 SYSTEM OBJECTIVES ....................................................................................................10
2.1.2 SYSTEM REQUIREMENTS...............................................................................................10
System Architecture ................................................................................................................11
1. User Interface Layer.......................................................................................................11
2. Application Logic Layer ..................................................................................................11
3. Data Storage Layer ........................................................................................................11
Technologies Used ..................................................................................................................12
Features of the System ............................................................................................................13
Book Management ..........................................................................................................13
ACKNOWLEDGEMENT
We take this occasion to thank God, almighty for blessing us with his grace and taking our
endeavor to a successful culmination. We extend our sincere and heartfelt thanks to our esteemed
guide, Mr.Shaurab Prasadfor providing us with the right guidance and advice at the crucial junctures
and for showing me the right way. We extend our sincere thanks to our respected Head of the
department Dr.Sudhir Kr singh, for allowing us to use the facilities available. We would like to
thank the other faculty members also, at this occasion. Last but not the least, we would like to thank
our friends and family for the support and encouragement they have given us during the course of our
work.
Library Management System
ABSTRACT
A Library Management System (LMS) is a digital solution designed to efficiently manage and automate
library operations, including book cataloging, user management, borrowing, returning, and fine
calculation. This system aims to streamline administrative tasks, improve accessibility, and enhance the
overall user experience for both library staff and patrons.
The LMS provides a centralized database for storing book details, member records, and transaction
histories, ensuring quick retrieval and reduced manual errors. By integrating modern technologies, the
Library Management System optimizes resource utilization, minimizes paperwork, and enhances library
services, making it an essential tool for educational institutions, public libraries, and private
organizations.
INTRODUCTION
This chapter gives an overview about the aim, objectives, background and operation environment
of the system.
Library Management System
Library Management System is an application which refers to library systems which are generally
small or medium in size. It is used by librarian to manage the library using a computerized system
where he/she can record various transactions like issue of books, return of books, addition of new
books, addition of new students etc.
Books and student maintenance modules are also included in this system which would keep track
of the students using the library and also a detailed description about the books a library contains.
With this computerized system there will be no loss of book record or member record which
generally happens when a non-computerized system is used.
In addition, report module is also included in Library Management System. If user’s position is
admin, the user is able to generate different kinds of reports like lists of students registered, list of
books, issue and return reports.
All these modules are able to help librarian to manage the library with more convenience and in a
more efficient way as compared to library systems which are not computerized.
Library Management System
1. Hardware Requirements
2. Software Requirements
SYSTEM ANALYSIS
In this chapter, we will discuss and analyze about the developing process of Library Management System
including software requirement specification (SRS) and comparison between existing and proposed system. The
functional and nonfunctional requirements are included in SRS part to provide complete description and
overview of system requirement before the developing process is carried out. Besides that, existing vs proposed
provides a view of how the proposed system will be more efficient than the existing one.
PROBLEM STATEMENT:
The problem occurred before having computerized system includes:
• File lost
When computerized system is not implemented file is always lost because of human
environment. Sometimes due to some human error there may be a loss of records.
• File damaged When a computerized system is not their file is always lost due to some
accident like spilling of water by some member on file accidentally. Besides some
natural disaster like floods or fires may also damage the files.
• Difficult to search record
After the number of records become large the space for physical storage of file and
records also increases if no computerized system is implemented.
• Cost consuming
As there is no computerized system the to add each record paper will be needed which
will increase the cost for the management of library.
USABILITY REQUIREMENT
The system is designed for a user-friendly environment so that student and staff of
library can perform the various tasks easily and in an effective way.
Library Management System
System Architecture
The Library Management System (LMS) is built using a layered architecture to organize different
functionalities efficiently. It consists of three key layers:
Technologies Used
This system is implemented using C programming language and uses various standard
libraries:
Technology Purpose
C Language Core programming language for logic implementation
File Handling (.txt/.dat) Persistent storage of book and student records
Input and output operations (printf, scanf, fopen,
<stdio.h>
fclose)
Memory management and program control (exit(),
<stdlib.h>
malloc())
<string.h> String handling functions (strcpy(), strcmp(), fgets())
<time.h> Capturing and formatting dates for book issuance
Library Management System
📚 Book Management
• Add Book: Users can enter book details like ID, title, author, and the date of addition.
• Modify Book: Allows users to update book details.
• Delete Book: Users can remove a book record.
• View Books: Displays a list of all available books.
🎓 Student Management
📌 Main Menu
7.Exit Submenu
When the user selects "7. Exit," the system terminates:
Library Management System
Source code
#include <stdio.h>
#include <stdlib.h>
#include <string.h>
#include <time.h>
struct Book {
int id;
char bookName[50];
char authorName[75];
char date[12];
};
struct Student {
int id;
char sName[50];
char sbranch[50];
int ssem;
int sRoll;
char bookName[50];
char date[12];
};
Library Management System
void addBook(void);
void booksList(void);
void modify_Book(void);
void issueBook(void);
void issueList(void);
void deleteBook(void);
int main() {
int choice = 1;
while (choice != 7) {
printf("\n7. Exit");
scanf("%d", &choice);
switch (choice) {
case 1:
Library Management System
addBook();
break;
case 2:
booksList();
break;
case 3:
modify_Book();
break;
case 4:
issueBook();
break;
case 5:
issueList();
break;
case 6:
deleteBook();
break;
case 7:
exit(0);
default:
}
Library Management System
return 0;
void addBook() {
struct Book b;
char myDate[12];
time_t t = time(NULL);
struct tm tm = *localtime(&t);
strcpy(b.date, myDate);
FILE *fp;
fp = fopen("books.txt", "a+");
if (fp == NULL) {
return;
scanf("%d", &b.id);
Library Management System
scanf("%s", b.bookName);
scanf("%s", b.authorName);
getchar();
ans = getchar();
fclose(fp);
void booksList() {
struct Book b;
FILE *fp;
printf("%-10s %-30s %-20s %s\n\n", "Book id", "Book Name", "Author", "Date");
Library Management System
fp = fopen("books.txt", "rb");
if (fp == NULL) {
return;
fclose(fp);
void modify_Book() {
struct Book b;
ft = fopen("temp.txt", "w");
fp = fopen("books.txt", "r");
return;
scanf("%d", &id);
while (!feof(fp)) {
if (b.id == id) {
scanf("%d", &b.id);
scanf("%s", b.bookName);
scanf("%s", b.authorName);
}
Library Management System
fclose(fp);
fclose(ft);
if (found) {
remove("books.txt");
rename("temp.txt", "books.txt");
} else {
getchar();
ans = getchar();
void issueBook() {
struct Student s;
struct Book b;
FILE *fp;
char myDate[12];
Library Management System
time_t t = time(NULL);
struct tm tm = *localtime(&t);
strcpy(s.date, myDate);
int found = 0;
scanf("%d", &s.id);
fp = fopen("books.txt", "rb");
if (fp == NULL) {
return;
if (b.id == s.id) {
strcpy(s.bookName, b.bookName);
found = 1;
break;
Library Management System
fclose(fp);
if (!found) {
return;
fp = fopen("issue.txt", "a+");
if (fp == NULL) {
return;
scanf("%s", s.sName);
scanf("%s", &s.sbranch);
scanf("%d", &s.ssem);
scanf("%d", &s.sRoll);
fclose(fp);
void issueList() {
struct Student s;
FILE *fp;
fp = fopen("issue.txt", "r");
if (fp == NULL) {
return;
while (!feof(fp)) {
fclose(fp);
void deleteBook() {
struct Book b;
scanf("%d", &id);
fp = fopen("books.txt", "rb");
if (fp == NULL) {
return;
ft = fopen("temp.txt", "wb");
if (ft == NULL) {
fclose(fp);
Library Management System
return;
if (b.id != id)
else {
found = 1;
fclose(fp);
fclose(ft);
if (found) {
remove("books.txt");
rename("temp.txt", "books.txt");
else {
remove("temp.txt");
}
Library Management System
Library Management System
Future Enhancement
References
• W3 schools
• Greeks for greeks
• Code with harry