Anda di halaman 1dari 2

May 7, 2019 [OBJECT ORIENTED PROGRAMMING]

Object oriented programming vs. Procedural Languages.

Procedural programming is structural programming languages which executed the code


sequentially depending on the instruction received through some subroutine and function calls.
Languages like C, COBOL are procedural language. Procedural programming (PP) is great
because it’s simple, typically straight forward (or can be written such that it is straightforward),
and with proper design, it allows good isolation and containment for variables when properly
scoped with functions and control loops.

While Object Oriented Programming brings the concept of classes which is a collection of
data and methods that relies on the operation of object. The concept of class and object brings
the dynamisms within a code and most importantly make the code reusable unlike procedural
language. Languages like System Verilog, java and C++ use the concept of OOP.

The major advantage of using OOP is:


 Introduces concept of Inheritance which is useful in extending the properties of base class
into child class along with its existing methods which increases code reusability and
minimizes code length.
 Introduces the concept of Encapsulation which is a data hiding property within a class so
that a particular data member can remain private.
 Introduces polymorphism concept using virtual methods which is useful in overriding class
properties and methods.
 Introduces abstract class concept which is just a placeholder for a class and object cannot
be created out of it and the use of it comes in task and function call.
 Introduces shallow copy, deep copy and object copy concept which are missing in
procedural language.
 Introduces multiple Inheritance and composition concept where a single child class can
inherit the properties of more than one class at the same time which helps in tremendous
reduction of code and minimizes debugging effort within a code.
 Introduces concept of observer pattern so that if a particular object within a class got
modified then extended data member which is dependent on that object gets updated
without any further modification of the code.
 OOP provides a clear modular structure for programs.
 It is good for defining abstract data types.

Made by UNEEB ULLAH


May 7, 2019 [OBJECT ORIENTED PROGRAMMING]

 Implementation details are hidden from other modules and other modules has a clearly
defined interface.
 It is easy to maintain and modify existing code as new objects can be created with small
differences to existing ones.
 Objects, methods, instance, message passing, inheritance are some important properties
provided by these particular languages
 Encapsulation, polymorphism, abstraction are also counts in these fundamentals of
programming language.
 It implements real life scenario.
 In OOP, programmer not only defines data types but also deals with operations applied for
data structures.

Features of object oriented programming:


 More reliable software development is possible.
 Enhanced form of c programming language.
 The most important Feature is that it’s procedural and object oriented nature.
 Much suitable for large projects.
 Fairly efficient languages.
 It has the feature of memory management.

Made by UNEEB ULLAH