Skip to content

About

C++ program demonstrating object-oriented programming with inheritance, class relationships, and operator overloading for student and course management (Object Oriented Programming, UNIWA).

Topics

Resources

Stars

0 stars

Watchers

0 watching

Forks

Latest commit

 

History

6 Commits

Folders and files

NameName
Last commit message
Last commit date
 
 
 
 
 
 
 
 

Repository files navigation

UNIWA

UNIVERSITY OF WEST ATTICA
SCHOOL OF ENGINEERING
DEPARTMENT OF COMPUTER ENGINEERING AND INFORMATICS

University of West Attica · Department of Computer Engineering and Informatics


Object-Oriented Programming

Inheritance

Vasileios Evangelos Athanasiou
Student ID: 19390005

GitHub · LinkedIn


Supervision

Supervisor: Cleo Sgouropoulou, Professor

UNIWA Profile · LinkedIn

Co-supervisor: Georgios Meletiou, Laboratory Teaching Staff

UNIWA Profile


Athens, June 2022



README

Inheritance

This repository contains a C++ program demonstrating student records management, focusing on course registration, grade handling, and OOP concepts such as inheritance, class relationships, and operator overloading.


Table of Contents

Section Folder/File Description
1 assign/ Assignment material for the Inheritance workshop
1.1 assign/Exercise3.png Exercise description in English
1.2 assign/Άσκηση3.png Exercise description in Greek
2 src/ Source code files for inheritance-based exercises
2.1 src/main.cpp Main C++ program
2.2 src/Course.cpp Implementation of the Course class
2.3 src/Course.h Header file for the Course class
2.4 src/Student.cpp Implementation of the Student class
2.5 src/Student.h Header file for the Student class
3 README.md Project documentation
4 INSTALL.md Usage instructions

1. Project Overview

The program demonstrates:

  • Creation and management of Student and Course objects
  • Class aggregation and relationships
  • Operator overloading for course addition, assignment, comparison, and output
  • Dynamic memory management with exception handling
  • Stream manipulation for outputting student data

2. Key Concepts

2.1 Class Relationships

  • Course Class Attributes:
    • Course Code, Course Name, Course Semester
  • Student Class Attributes:
    • Declared Courses (currently enrolled)
    • Passed Courses (completed with grade)

2.2 Operator Overloading

  • += Operator: Adds a course to a student’s declared courses
  • Assignment Operator (=): Copies student attributes
  • Comparison Operators (==, !=, <, <=, >, >=): Compares students by semester
  • Stream Insertion Operator (<<): Outputs detailed transcript and average GPA

2.3 Exception Handling

  • Handles errors during dynamic memory allocation and file operations
  • Provides meaningful error messages for memory or file access failures

3. Functionality

Key functions include:

  • Adding courses to a student’s record (+=)
  • Copying student attributes (assignment operator)
  • Comparing students by semester
  • Outputting student transcripts using stream insertion

4. Conclusion

This project illustrates OOP inheritance and class relationships in C++, combining dynamic memory management, operator overloading, and exception handling to implement a functional student-course management system.

About

C++ program demonstrating object-oriented programming with inheritance, class relationships, and operator overloading for student and course management (Object Oriented Programming, UNIWA).

Topics

Resources

Stars

0 stars

Watchers

0 watching

Forks

Releases

Packages

Used by

Contributors

Languages