Object-Oriented Programming in C++: A Comprehensive Tutorial

Object-Oriented Programming in C++: A Comprehensive Tutorial

This tutorial has been developed by Zubair Muhammad and Zaeem Muhammad, undergraduate students of the Department of Software Engineering, University of Sargodha, under the guidance of Dr. Afzal Badshah. It covers essential Object-Oriented Programming (OOP) concepts practised during the semester, such as classes, objects, inheritance, polymorphism, and encapsulation, with practical examples in C++. The study plan and books can be accessed here.

Associations, Aggregation & Composition in OOP (C++)

Object-Oriented Programming is not only about creating classes and objects, it is also about how objects interact with each other ...

C++ Templates and Standard Template Library (STL): A Complete Beginner-Friendly Tutorial

Imagine running a grocery shop. You use different delivery boxes for apples, oranges, and eggs etc. But using a separate ...

Operator Overloading in C++: Teaching Objects to Behave Like Natural Data Types

Operator overloading is a simple yet powerful concept in C++. Imagine how naturally we use operators in daily life. We ...

Virtual and Pure Virtual Functions in C++

In our previous lessons, we explored how inheritance allows one class to reuse and extend the features of another. We ...

Abstract Classes and Interfaces — Designing Extensible Frameworks

In our previous lecture, we explored virtual and pure virtual functions.We saw how a virtual function allows different derived classes ...

Polymorphism in C++ | OOP Tutorial with Real-Life Examples

Polymorphism is one of the four core concepts of Object-Oriented Programming (OOP), along with encapsulation, inheritance, and abstraction. The term ...

Constants in OOP – C++

In our daily life, there are some values that never change. For example: The number of days in a week ...

Introduction to Object-Oriented Programming (OOP)

Object-Oriented Programming (OOP), is a way of writing programs by focusing on real-life objects. In the real world, everything we ...

Classes and Objects in C++: Beginner’s Guide with Real-Life Examples

Programming is about solving real-life problems. Imagine you're designing a software to manage a car showroom, or a student database ...

Static Data Members and Functions in C++

In daily life, some things are shared by everyone rather than belonging to just one person. For example, in a ...