Comparing C and C++
The very basic difference is C++ is an Object Oriented Language and C is a procedural language .
In 1972 Denis Ritchie developed C language , whereas C++ developed at AT&T Bells laboratories in early 1980s by Bjarne Stroustrup.
C++ was made by adding additional features to languages like Simula67 (The first Object Oriented Language ) and C . C++ was originally named as “C with Classes”. The Rick Mascitti named it C++ (pronounced as plus plus).
Now as we know C++ is Object Oriented Language , that is a programming paradigm based on the concept of “objects”, which has concept like classes and object , Inheritance , Data Abstraction , polymorphism and Encapsulation . So these concept are not in C.
In C for input we use scanf() and for output we use printf() where as in C++ we use cin for input and cout for output.
C file is stored with extension .c and C++ file is stored with extension .cpp
allocation of dynamic location in C is through malloc() & calloc() and memory is deallocation by free() . In C++ allocation done through new and deallocation through delete.
There is no concept of Constructor and Destructor in C on the other hand C++ has concept of both constructor and Destructor.
Operator and Function Overloading are not support in C but they are supported by C++.
Multiple declaration of global variable is allowed in C but not in C++.
Both supports pointer concept and both are case sensitive languages.
virtual and friend concept are not in C but these two concept are supported by C++.
Inline function are supported in C++ not in C.
so we can conclude that C is a subset of C++ .