Difference Between C and C++ Language| C VS C++
C and C++ are programming languages. C++ is the improved version of the C language. The name of “C” language comes from “B” language similarly some features are extended in “C” language named as C++. Here plus plus “++” shows the some features added in C language. This is about the difference in naming of C and C++. Now let us discuss which features are added in C language then they become C++.
Difference between C and C++ programming language:
C is Procedure Oriented Programming Language (POP) on other hand C++ supports OOP (object oriented) that means C++ is Multi-paradigm.
C is less user friendly so it is low level language but C++ is user friendly Language it has both features like low level and middle level as well.
C++ supports function overloading due to the presence of feature named polymorphism but C does not supports.
C uses scanf & printf while C++ uses cin>> & cout<< for their respective input & output functions.
Program saved in the C language with .C (dot C) extension while in C++ it is saved as .CPP (dot CPP “pp” means plus plus).
Top down approach is used in C language on other hand Bottom up approach is used in the C++.
The header file used in C language is stdio.h (default header file) and in C++ it is iosteam.h.
The most important features in the C++ are the OOP’s. These features are described below.
The data abstraction- The main function of data abstraction is data hiding. It is the process of representing the data members and the member functions without showing the internal details.
Encapsulation-the actual meaning of Encapsulation is providing Security therefore it wrapping up of data members and member’s functions into a single entity.
Polymorphism-Polymorphism means many forms. Due to the presence of this feature it is the ability to take more than one form.
Inheritance- this feature helps to inherits the Properties of base class to derived class same as real life example son inherits some properties of their father. It is of five types-
1. Single Inheritance
2. Hybrid inheritance
3. Multilevel inheritance
4. Multiple inheritance
5. Hierarchical Inheritance
C and C++ are programming languages. C++ is the improved version of the C language. The name of “C” language comes from “B” language similarly some features are extended in “C” language named as C++. Here plus plus “++” shows the some features added in C language. This is about the difference in naming of C and C++. Now let us discuss which features are added in C language then they become C++.
Difference between C and C++ programming language:
C is Procedure Oriented Programming Language (POP) on other hand C++ supports OOP (object oriented) that means C++ is Multi-paradigm.
C is less user friendly so it is low level language but C++ is user friendly Language it has both features like low level and middle level as well.
C++ supports function overloading due to the presence of feature named polymorphism but C does not supports.
C uses scanf & printf while C++ uses cin>> & cout<< for their respective input & output functions.
Program saved in the C language with .C (dot C) extension while in C++ it is saved as .CPP (dot CPP “pp” means plus plus).
Top down approach is used in C language on other hand Bottom up approach is used in the C++.
The header file used in C language is stdio.h (default header file) and in C++ it is iosteam.h.
The most important features in the C++ are the OOP’s. These features are described below.
The data abstraction- The main function of data abstraction is data hiding. It is the process of representing the data members and the member functions without showing the internal details.
Encapsulation-the actual meaning of Encapsulation is providing Security therefore it wrapping up of data members and member’s functions into a single entity.
Polymorphism-Polymorphism means many forms. Due to the presence of this feature it is the ability to take more than one form.
Inheritance- this feature helps to inherits the Properties of base class to derived class same as real life example son inherits some properties of their father. It is of five types-
1. Single Inheritance
2. Hybrid inheritance
3. Multilevel inheritance
4. Multiple inheritance
5. Hierarchical Inheritance