This is a console-based Hospital Management System developed using C++, demonstrating all major Object-Oriented Programming (OOPs) principles. The system simulates hospital workflows such as booking appointments, managing users, and storing patient records.
β
Admin (Manage records)
β
Doctor (Diagnose patients)
β
Patient (Book appointments)
- Role-Based Access Control
- File-Based Data Storage
- Appointment Booking System
- Medical History Tracking
- Diagnosis Management
- Viewing and Storing Medical Records
| Concept | Implementation Example |
|---|---|
| Inheritance | Doctor and Patient inherit from Person |
| Polymorphism | Virtual displayInfo() function |
| Encapsulation | Private data members with public getters |
| File Handling | Store medical records and appointments |
| Friend Class | Admin accessing patient/doctor data |
Hospital-Management/
βββ include/ # Header files
β βββ Person.h # Base class
β βββ Admin.h # Admin operations
β βββ Doctor.h # Doctor functions
β βββ Patient.h # Patient functions
βββ src/ # Implementation
β βββ Person.cpp
β βββ Admin.cpp
β βββ Doctor.cpp
β βββ Patient.cpp
β βββ main.cpp # Entry point
# Compile
g++ -Iinclude src/*.cpp -o hospital.exe
# Run
hospital.exe# Compile
g++ -Iinclude src/*.cpp -o hospital
# Run
./hospital