Object-Oriented Programming
What Is Object-Oriented Programming (OOP)?
Also called: OOP
Object-oriented programming (OOP) organizes code into objects that bundle data with the methods that work on it, built from classes.
Definition
Object-oriented programming is a way of structuring a program around objects. Each object combines data (attributes) with the actions that use it (methods), and objects are created from classes.
Java, C#, C++, Python and Ruby all support OOP, and it is the most common style in large business applications.
How it works
OOP rests on four ideas. Encapsulation keeps an object’s data behind its methods. Abstraction exposes only what other code needs. Inheritance lets one class reuse another. Polymorphism lets different classes answer the same method call in their own way.