Skip to content

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

2 Commits
 
 
 
 

Repository files navigation

📚 Library Management System

A console-based Library Management System built in C++ using file handling and object-oriented programming. It allows librarians to manage books and students, and handles book issuing and return with automated fine calculation.


🗂️ Features

Module Operations
Books Add, display, modify, delete
Students Add, display, modify, delete
Book Issue Issue a book to a student (one book per student)
Book Deposit Return a book with fine calculation (₹1/day after 15 days)
Reports List all books / all students

🖥️ Menu Structure

Main Menu
├── 1. Book Issue
├── 2. Book Deposit
├── 3. Administrator Menu
│   ├── Create / Display / Modify / Delete Student Records
│   ├── Create / Display / Modify / Delete Book Records
│   └── Back to Main Menu
└── 4. Exit

🧱 Code Structure

Classes

book

  • Stores book number, book name, and author name
  • Methods: createbook(), showbook(), modifybook(), report()

student

  • Stores admission number, name, issued book number, and token (issue status)
  • Methods: createstudent(), showstudent(), modifystudent(), report()
  • Token system: 0 = no book issued, 1 = book currently issued

Data Storage

Records are persisted to binary files using C++ file streams (fstream):

File Contents
book.dat All book records
student.dat All student records

⚙️ Setup & Usage

Requirements

  • Turbo C++ (originally written for DOS-era compiler)
  • To compile on modern systems, replace legacy headers:
Legacy Header Modern Equivalent
iostream.h iostream
fstream.h fstream
iomanip.h iomanip
conio.h Remove / replace clrscr(), getch()
stdlib.h cstdlib

Compile (Modern GCC)

g++ LMSCode.cpp -o lms
./lms

⚠️ You may need to remove or stub out clrscr(), getch(), and gotoxy() calls, as these are Turbo C++ specific.


📌 Known Limitations

  • Only one book can be issued per student at a time.
  • Book and admission numbers are limited to 5 characters.
  • No password protection on the Administrator menu.
  • Fine rate is hardcoded at ₹1/day (after a 15-day grace period).
  • Built for Turbo C++ — minor refactoring needed for modern compilers.

🛠️ Possible Improvements

  • Migrate to modern C++ (std::string, std::vector, STL file I/O)
  • Add login authentication for the admin panel
  • Support multiple book issuance per student
  • Replace binary file storage with SQLite for reliability
  • Add a due-date tracker instead of manual day entry

👤 Author

Chahat — Academic project demonstrating file handling and OOP in C++.

About

Console-based Library Management System in C++ — manages books & students with file-based storage, book issue/return tracking, and fine calculation.

Topics

Resources

Stars

Watchers

Forks

Releases

Packages

Contributors

Languages