9448474282
learn@ismuniv.com

Single Blog Title

This is a single blog caption
11 May 2016

Differences between C and C++ Explained by ISM UNIV

/
Posted By
/
Comments0

Differences between C and C++ Explained by ISM UNIV

 Let us check basic introduction about the programming languages and Differences between C and C++ Explained by ismuniv, C and C++. The programming language C++ is derived exclusively from the programming language C and it is always termed as super set of the C. In fact, people used to call C++ in earlier days as C language with classes. What is making here C++ a super set is its class’s addition and inheritance mechanism with class objects to the other classes. Also, it is possible to compile your C programs successfully using C++ compilers too. Importantly, expressions in C++ and C are same too besides keeping all the C operators as valid with C++. So, these basics itself are clearly signifying the similarities between both programming languages.

Let us see differences between both programming languages:

  • C is a procedural programming language while C++ is not because it is an object orient language.
  • There will be no virtual functions in C while C++ uses successfully the concept of the virtual functions in it.
  • The C is lacking polymorphism and this is an important OOPS feature. C++ uses the concept of the polymorphism in it.
  • C doesn’t have operator overloading while C++ features mainly operator overloading in it.
  • Program language C uses Top Down process or approach in the programming design and C++ adopts Bottom UP approach in it.
  • Namespace feature lacking in C and C++ uses it in order to avoid name collision.
  • C allows global variable multiple declarations while C++ does not.
  • Input and Output functions are used differently in these languages.
  • Mapping between function and data is complicate procedure with C while C++ maps it wisely using “objects”.
  • It is easy to call main () functions with other function(s), but C++ cannot.
  • It is imperative to define all variables at the beginning of the scope in C and C++ allows this declaration of the variables anywhere within scope.
  • Inheritance feature cannot be seen with C while C++ features it.
  • C supports primitive as well as built-in data types and C++ supports user define and built-in type data.
  • Exceptional handling is not possible with C and C++ does it through Catch block and Try.

Leave a Reply

Share