C++ Introduction
C++ is an object - Oriented Programming language. It was developed by ' Bjarne Stroustrup ' at AT & T Bell Laboratories in Murray Hill, New Jersey, USA in the early 1980's.
Stroustrup, an admirer of Simula67 and a strong supporter of C, wanted to combine the best of both the language and create a more powerful language that could support Object - Oriented Programming feature and still retain the power and elegance of C. The result was C++.
We can say that C++ is an extension of C with a major addition of class construct feature of Simula67.
The most important facilities that C++ adds on to classes, Inheritance, function overloading and operator overloading. These features enable creating of abstract data types, inherit properties from existing data types and support Polymorphism, thereby making C++ a truly Object - Oriented language.
Note: C++ is not purely Object - Oriented language because the word Object - Oriented means whole program written with the help of Class and Objects, but in C++ program can be write without use of Class & Objects.
Object-oriented Programming Paradigm
The core of Object- Oriented Programming is to creating Objects which has certain properties and methods. Object- Oriented Programming (OOP) was invented to overcome the drawbacks of the POP.
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 builds data and functions around these Objects.
Emphasis is on data rather than procedure.
Programs are divided into what are known as Objects.
Data structures are designed such that they characterize the objects.
Functions that operate on the data of an object are tied together in the data structure.
Data is hidden and cannot be accessed by external functions.
Ojects may communicate with each other through functions.
New data and functions can be easily added whenever necessary.