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

Answers were Sorted based on User's Feedback



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

Answer / shashank mishra

c is structure programming language but c++ is object
orinted language

Is This Answer Correct ?    3 Yes 0 No

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

Answer / arpit parikh

c lagauge is a first part of to be a computer engineer.&
c++ is second part of for that.this is only my opinion.

Is This Answer Correct ?    3 Yes 1 No

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

Answer / e.e.n.bashy

c programming language is top down approach while c++
programming language is bottom up approach

Is This Answer Correct ?    2 Yes 0 No

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

Answer / radha garg

c is structure level and difficult to use ...........bt c
is on object based and easy to use

Is This Answer Correct ?    2 Yes 0 No

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

Answer / kunal kumar

* C does not have any classes or objects. It is
procedure and function driven. There is no concept of access
through objects and structures are the only place where
there is a access through a compacted variable. c++ is
object oriented.


* C structures have a different behaviour compared to
c++ structures. Structures in c do not accept functions as
their parts.


* C input/output is based on library and the processes
are carried out by including functions. C++ i/o is made
through console commands cin and cout.


* C functions do not support overloading. Operator
overloading is a process in which the same function has two
or more different behaviours based on the data input by the
user.


* C does not support new or delete commands. The memory
operations to free or allocate memory in c are carried out
by malloc() and free().


* Undeclared functions in c++ are not allowed. The
function has to have a prototype defined before the main()
before use in c++ although in c the functions can be
declared at the point of use.


* After declaring structures and enumerators in c we
cannot declare the variable for the structure right after
the end of the structure as in c++.


* For an int main() in c++ we may not write a return
statement but the return is mandatory in c if we are using
int main().


* In C++ identifiers are not allowed to contain two or
more consecutive underscores in any position. C identifiers
cannot start with two or more consecutive underscores, but
may contain them in other positions.


* C has a top down approach whereas c++ has a bottom up
approach.


* In c a character constant is automatically elevated to
an integer whereas in c++ this is not the case.


* In c declaring the global variable several times is
allowed but this is not allowed in c++.

Is This Answer Correct ?    2 Yes 0 No

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

Answer / radhika

In c progam are save usig .c extension
In c++ program are save usig .cpp extension

Is This Answer Correct ?    2 Yes 0 No

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

Answer / saraswathi

Difference between c and C++

C C++

1. C is a procedure oriented programming C++ is a object
oriented programming

2. C uses #include<stdio.h> C++ uses #include<iostream.h>

3. In C main focus is on functions In C++ main focus is on
data rather than functions. Data is not freely moved around
the system rather the functions exists in the object are the
only means by which the data can be accessed

4. In C No Data security In C++ data is hidden and is
secure from unauthorised access

5. In C there is no concepts like encapsulation,
polymorphism , inheritance etc. C++ provide encapsulation,
polymorphism, inheritance etc.

Is This Answer Correct ?    2 Yes 0 No

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

Answer / rajan bajlalia pathankot

C Is very easy language. and c++
is very hot languege. c is procedural programming language.
and c++ is object oriented languege. c language is used by
main(). and c++ is used by viod main(). c is used by
#<include.h> and c++ is used is A#include<iostreame>.
c is printf/scanf used by output/input.c is a topdown
approach while c++ is bottom up approach.C++ support
operator overloading but c doesn't
support
operator overloading.C is a LOW level language.
C++ is a HIGH level language.we have used by c is
semicolom. and c++ is not used by semicolom. c is length
programming and c++ is not length programming.

Is This Answer Correct ?    3 Yes 1 No

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

Answer / waseem akram

The major difference between c & c++ is OOPs Concept..C
doesnt haves this C++ has this.

Is This Answer Correct ?    3 Yes 1 No

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

Answer / p vasavi

C++ IS THE ADVANCED VERSION OF C


* C IS A TOP DOWN APPROACH WHEREAS C++ IS A BOTTOM UP
APPROACH.

* C IS A OBLECT BASED PROGRAM THEY USE LIKE STRUCTURE AND
UNIONS WHEREAS C++ IS OBJECT ORIENTED PROGRAMMING THAT
MEANS ENTIRE PROGRAM IS MAINLY BASED ON OBJECT AND OBJECT
ORIENTED PROGRAMMING IS REUSEABILITY INCREASES THE
EFFICIENCY OF THE PROGRAM

* DATA IS NOT SECURED IN C WHEREAS IN C++ DATA IS SECURED

* IN C WE ARE USING #INCLUDE<STDIO.H> WHEREAS IN C++ WE
ARE USING #INCLUDE<IOSTREAM.H>

Is This Answer Correct ?    2 Yes 0 No

Post New Answer

More OOPS Interview Questions

what is diff between .net 1.1 and .net 2.0

4 Answers  


what is a binary overloading

2 Answers  


What is oops in programming?

0 Answers  


difference between structure and union.

2 Answers   ADP, Convergys,


what are the realtime excercises in C++?

0 Answers   IBM, Wipro,






What normal C constructs work differently in C++?

2 Answers  


What do you mean by pure virtual functions?

8 Answers  


Can we have a private constructor ?

12 Answers   HSBC, Ness Technologies, TCS, Wipro,


What is overriding in oops?

0 Answers  


What is advantage of inheritance?

0 Answers  


which is platform independent device used in computers

2 Answers  


What is polymorphism what is it for and how is it used?

0 Answers  


Categories