
Object-oriented programming is a programming paradigm, or classification, that organizes a group of data attributes with functions or methods into a unit, known as an object. Typically, OOP languages are class-based, meaning a class defines the data attributes and functions as a blueprint for creating objects, which are instances of the class. One class may represent multiple independent objects, which interact with each other in complex ways. Popular class-based programming languages include Java, Python and C++.
For example, if a class represents a person, it may contain attributes to represent various data, such as the person's age, name and height. The class definition might also contain functions, such as a function to print the person's name on a screen. You could create a family by representing person objects from the class of each family member. Each person object contains different data attributes because every person is unique.
- Teacher: Esraq Humayun