Introduction to Object Oriented Programming

In this series of Blogs we are going to develop a system for performing the functionalities like SQL(like insertion, deletion and modifying the records) using the concepts of Object Oriented Programming in C++.
But before that it is important to know the background and features of OOPS. 


The prime purpose of C++ programming was to add object orientation to the C programming language, which is in itself one of the most powerful programming languages.
The core of the pure object-oriented programming is to create an object, in code, that has certain properties and methods. While designing C++ modules, we try to see whole world in the form of objects. For example a car is an object which has certain properties such as color, number of doors, and the like. It also has certain methods such as accelerate, brake, and so on.
With this concept lots of feature comes along with it like class,object, abstraction, encapsulation, polymosrphism and so on.

Why OOP?
The major motivating factor in the invention of object-oriented approach is to remove some of the flaws encountered in the procedural approach. OOP treats data  as a critical element in the program development and does not allow it to flow freely around the system. It ties data more closely to the functions that operate on it and protects it from accidental modification from outside functions. 
OOP allows decomposition of a problem into a number of entities called objects and then build data and functions around these objects.

Some features of OOP:


  • Emphasis on data rather than procedure.
  • Program are divided into what are known as objects.
  • Data is hidden and cannot be accessed by external functions.
  • New data and functions can be easily added whenever necessary.
  • Objects can communicate with each other through functions.
Image result for object oriented programming
Object oriented programming over procedural programming- 
One of the most important characteristics of procedural programming is that it relies on procedures that operate on data - these are two separate concepts. In object-oriented programming, these two concepts are bundled into objects. This makes it possible to create more complicated behavior with less code. The use of objects also makes it possible to reuse code. Once you have created an object with more complex behavior, you can use it anywhere in your code.



Comments

  1. Very informative and we'll explained

    ReplyDelete
  2. This comment has been removed by the author.

    ReplyDelete

Post a Comment

Popular posts from this blog

SEARCHING

ORDER BY PART-2

GROUP BY