What is object-oriented programming? How is different from procedural programing?


Java, JavaScript, Python, C++, Visual Basic .NET, Ruby, Perl, Scala, Swift, Dart, PHP are all examples of OOP languages. However, just because a program is written in the languages listed does not mean the program itself is Object Oriented. OOP provides a clear structure for the programs. OOP helps to keep the C++ code DRY aka "Don't Repeat Yourself", and makes the code easier to maintain, modify and debug. OOP makes it possible to create full reusable applications with less code and shorter development time. In OOP when individual objects are created, they inherit all the variables and functions from the class.

Procedural Programming

Procedural programming is a programming paradigm. A programming paradigm is a type of programming thinking or methodology in software construction. Another name for procedural programming is inline programming. This programming style is derived from structured programming, based upon the concept of the procedure call. Procedures are also known as routines, subroutines, or functions which simply contain a series of computational steps to be carried out. FORTRAN, ALGOL, COBOL, BASIC, Pascal and C are all examples of procedural programming languages.


There are many side by side differences between OOP and Procedural Programming (PP). PP programs are divided into functions whereas OOP divides into objects. PP has a top down approach and OOP has a bottom up approach. OOP has access specifiers like private, public, and protected. Also, new data and functions are added easily. OOP has data hiding so it is more secure than PP. In PP overloading is not possible which is in stark contrast to OOP.



No Comments Yet.

leave a reply