OOP vs PP

OOP vs PP

Object-oriented Programming versus Procedural Programming
Whether it is Object-Oriented or Procedural Programming, programming in general is dealing with or looking at data and the code that can and will change the data (output) in some way. Object-Oriented vs. Procedural Programming can be said to be ways we handle the coding of the data – how it is written perhaps. We need to apply different thinking and strategies when we write code, and it can be either Object-Oriented or Procedural Programming.
In Procedural Programming, we group our code into procedures, hence the name Procedural Programming. These procedures are instructions on how we use and manipulate the data. With Procedural Programming we have code that is read line by line, taking input (instructions) to do something with the goal of an output. The code is read (data taken in) in exchange for an output. With Procedural Programming, you can write code all day long that do not have an existing relationship to the data used. Procedural Programming functions use code (data) provided and can access shared data needed, but a relationship does not exist. Procedural Programming uses traditional programming languages like C, COBOL and Pascal. In short, Procedural Programming is about using and choosing data structures, creating your algorithms, and converting algorithms into code. With Procedural Programming, data and operations of the data or with the data are separate (no relationship exist). You send data to procedures and functions. Simply, you have a function that is applied on data elements giving you a function (data) in return.
With Object Oriented Programming, data and functions are bundled (called an "object"). With Object Oriented Programming, unlike Procedural Programming, objects do not access shared data. With Object Oriented Programming, the objects are allowed to only use data provided. Like the name, Object Oriented Programming is focused on objects versus procedures and...

Similar Essays