Sunday, 4 January 2015

Difference between C and C++

Sr. No.
C++ Language
C is a procedural programming Language.
C++ is a multi-paradigm
language which means it is procedural as well as object
oriented language.
In C, importance is given to the steps or procedure of the program.
C++ focuses on the data rather than the process.
Data is not secure because oops feature such as data hiding etc. are not present in C.
Data is secure because it supports oops concepts.
C is a low-level Language.
It is Middle level Language.
C uses the top-down approach .Program is formulated step by step,
each step is processed into detail.
C++ uses the bottom-up approach. In C++ base elements are
first formulated which then are linked together to give rise to larger systems.
C is function-driven and Functions are the building blocks of a C program.
It is object-driven and objects are building blocks of a C++ program.
Function overloading is not supported in C.
It Supports Function Overloading.
It does not support NAMESPACE.
C++ uses NAMESPACE which avoid name collisions
It uses Printf, Scanf as standard input & output functions.
It uses cout<<, cin>> as standard input & output functions.
Reference Variables are not supported in C language.
C++ allows the use of reference variables which allow two variable names to point to the same memory location.
Alternate Links
Compare C and C++ Programming Languages
How C language is different from C++ programming language?
Difference between C and C++

1 comment:

  1. Difference between c and c++

    The main difference between C and C++ is, C is the procedure oriented language and C++ is the object oriented language.