Skip to content

Skyl1te/StudentManagementSystem

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

5 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

🎓 Student Management System (C++)

A console-based Student Management System written in modern C++ with support for JSON persistence, fast lookups, undo/redo functionality, and flexible search.


🚀 Features

📌 Core functionality

  • Add / delete / update students

  • View all students

  • Search by:

    • ID
    • Name
    • Surname
    • Full-text query (multi-word search)

⚡ Performance

  • O(1) student lookup by ID using unordered_map
  • Optimized deletion without shifting elements

💾 Data persistence

  • Data is stored in JSON format
  • Automatic load/save from file

🔄 Undo / Redo

  • Full state history
  • Supports reverting and reapplying actions

🔍 Advanced search

  • Case-insensitive search

  • Partial matches supported

  • Multi-word query search:

    Jon Snow
    

    matches:

    Jon Snow
    Snow Jon
    

📊 Sorting

  • Sort by:

    • ID
    • GPA
    • Age
    • Name
    • Surname

🎯 Filtering

  • Filter by GPA
  • Filter by age range

🧠 Architecture

Data structures

  • std::vector<Student> — main storage
  • std::unordered_map<int, int> — index for O(1) access
  • history / redoStack — state snapshots for undo/redo

Complexity

Operation Complexity
Add student O(1)
Get by ID O(1)
Delete O(1)
Search O(n)
Sort O(n log n)

📁 Project Structure

.
├── main.cpp
├── Student.h / Student.cpp
├── StudentManager.h / StudentManager.cpp
├── students.json
└── json.hpp (nlohmann/json)

🛠 Technologies


▶️ How to run

1. Compile

g++ main.cpp Student.cpp StudentManager.cpp -o app

2. Run

./app

📄 Example JSON

[
    {
        "id": 1,
        "name": "Jon",
        "surname": "Snow",
        "age": 20,
        "gpa": 4.5
    }
]

💡 What I learned

  • Working with STL containers
  • Designing efficient data structures (indexing)
  • Implementing undo/redo systems
  • File persistence with JSON
  • Writing modular and maintainable C++ code

🔥 Future improvements

  • GUI (Qt / ImGui)
  • Database integration (SQLite)
  • Unit tests
  • CLI arguments support
  • Export/import CSV

👤 Author

GitHub: https://github.com/Skyl1te


⭐️ If you like this project

Give it a star and feel free to contribute!

About

A console-based Student Management System written in modern C++ with support for JSON persistence, fast lookups, undo/redo functionality, and flexible search.

Topics

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

 
 
 

Contributors

Languages