what is the main difference between c and c++?

Answer Posted / ajit kumar singh

The basis difference that c is structural Language and C++
is Object Oriented language addition with that C++ is super
set of c.
So C++ having all functionality that c have with addition
with Object Oriented functionality i.e Classes ,Operator
overloading etc.

So all other difference born from to fulfill these requirements.
So some c functionality is modify in C++ and some new added.

for example.
Modified :
1.In use of enum
2.In use of function
3.In size of Array
4. Type comaptibility
5.In use of Void pointer
6.Scope of Variable
7.Place of variable declartion
etc... You can find many more thing
Added new
1. Class
2. Reference variable
3.Dynamic initialization of variable
4. some more operator
5. new data type
6. new type of function (virtual ,friend,inline etc)
there are lot of minor difference and new...just check with
some good book....
but please don't pur misleading answer..

1.Class

Is This Answer Correct ?    0 Yes 0 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

What is abstraction oop?

619


Why is it so that we can have virtual constructors but we cannot have virtual destructors?

3818


Why is abstraction used?

599


How to hide the base class functionality in Inheritance?

634


What are oops functions?

580






Which type does string inherit from?

608


What is polymorphism oop?

614


write a program that takes input in digits and display the result in words from 1 to 1000

1982


What does no cap mean?

590


write a code for this:trailer recordId contains a value other than 99, then the file must error with the reason ‘Invalid RECORD_ID’(User Defined Exception).

1636


Why is object oriented programming so hard?

610


What is destructor example?

591


Why polymorphism is used in oops?

578


What is a superclass in oop?

665


What are constructors in oop?

586