A Good and popular Appproach to build a Software is using OOP.

That means creating Objects and Classes to organize Software.


Threee main thing of OOP is: (Inheritance, Encapsulation, Polymorphism)



Inheritance


"Inheritance" is used to reduce repetition of Attributes and Methods.
To inherit, just pass the Parent Class to the Child Class, that's all
"Inheritance" reduces the size of Code and maintains the law or concept of Code Reusability



Encapsulation


Encapsulation is used to protect Attributes from the outsiders. Like declaring private, protected Attributes.
Encapsulation is used to Encapsulate the functionality of code. That's why, users don't need to see what's happening inside of Software of Algorithm



Polymorphism


Polymorphism means Different or Multiple conditions or phases.
In OOP it's used to mean the different or multiple uses of any Class or Objects or Attribute or Method or whatever.
It just denotes Multiple Phases. Search on Google for more info