Professional Documents
Culture Documents
into objects, which are instances of classes, and fosters the principles of
encapsulation, inheritance, and polymorphism. In OOP, software is designed and
structured around real-world entities and their interactions, allowing for a more
intuitive representation of complex systems.
Class:
An instance of a class, representing a specific entity with its own unique state
and behavior.
Encapsulation:
The bundling of data and methods that operate on the data within a single unit
(object). It involves hiding the internal details of an object and exposing only
what is necessary.
Inheritance:
A mechanism that allows a new class (subclass or derived class) to inherit the
properties and behaviors of an existing class (superclass or base class). It
promotes code reuse and the creation of hierarchical relationships between classes.
Polymorphism: