THE DIFFERENCE BETWEEN PROCEDURAL PROGRAMMING & OBJECT ORIENTED PROGRAMMING
All computer program holds two elements:
![]() |
Ya... You guessed it right...data and code.
Furthermore, a program is organized when it is revolving around its code or data.
Example of how some programs are written:
What is happening?
Who is being affected?
Two paradigms that govern how a program is executed:
Process Oriented model
This approach characterizes a program as a series of linear steps (this relates to code). This approach is regarded as code acting on data.
**Problems occur as program grows larger and more complex
Object Oriented Programming
This approach is able to manage increasing complexity. Object Oriented Programming organizes a program around its data (this will be objects). This approach is characterized as data controlling access to code.
**By switching the controlling entity to data, you can achieve organizational benefits.
ABSTRACTION
Abstraction or data abstraction is the process of hiding certain details and showing only essential information to the user.
Example:
From the outside, the car is a single object.
Once you go in, you will notice that the car consists of steering, brakes, sound system, seat belts and more.
In turn, these subsystems are made up of more special units. For instance, the sound system consists of a radio, or even a CD player.
With this example, it shows the hierarchical abstraction of complex systems which can also be applied to computer programs.
ENCAPSULATION, INHERITANCE & POLYMORPHISM
Encapsulation is the mechanism that binds together code and the data it manipulates and keeps both safe from the outside interference and misuse.
AN INTRODUCTION TO JAVA:


Nice 👍 your Article......
ReplyDelete(Free) Competitive Programming Course in Hindi+English
(Free) Competitive Programming Course in Hindi+English
(Free) Competitive Programming Course in Hindi+English
(Free) Competitive Programming Course in Hindi+English
(Free) Competitive Programming Course in Hindi+English
(Free) Competitive Programming Course in Hindi+English
(Free) Competitive Programming Course in Hindi+English
(Free) Competitive Programming Course in Hindi+English