DIFFERNCE BETWEEN THE C++ AND C LANGUAGE?

Answers were Sorted based on User's Feedback



DIFFERNCE BETWEEN THE C++ AND C LANGUAGE?..

Answer / vignesh1998i

1) C is structured oriented language and C++ is an object oriented language
2) in C we must finish our decleration in the very next line of void main() , but in Cpp wherever u need a variable storage data , before that instruction we must declare it......
3) In C structures are used , in that only data members can only be declared and member functions not included , but in Cpp inside a class (same as strucutres) both data members as well as member functions can be used..
4) in Structure all the members and strucutre variables are global by default...... but in Cpp by default the data members are private.....


SIMILARITY :
1) both C & C++ uses Overloading concept....... (very important )

thank u

Is This Answer Correct ?    3 Yes 1 No

DIFFERNCE BETWEEN THE C++ AND C LANGUAGE?..

Answer / manish soni tagore collage jai

main deference in c and cpp is



-------------------|-------------------|
c | c++ |
-------------------|-------------------|
top down approach | bottom up approach|
-------------------|-------------------|

Is This Answer Correct ?    1 Yes 0 No

Post New Answer

More C Interview Questions

main() { printf("hello"); fork(); }

0 Answers   Wilco,


Why we not create function inside function.

0 Answers  


what is mean by Garbage collection ? Please answer me. Advance thanks.

4 Answers   Excel,


What is the difference between char a[] = "string"; and char *p = "string"; ?

14 Answers   Adobe, Honeywell, TCS,


What is sparse file?

1 Answers  


What is the difference between declaring a variable by constant keyword and #define ing that variable?

1 Answers  


write a “Hello World” program in “c” without using a semicolon?

9 Answers   CTS, TCS, Wipro,


Write a program to generate prime factors of a given integer?

2 Answers  


Apart from dennis ritchie who the other person who contributed in design of c language.

0 Answers  


Are negative numbers true in c?

0 Answers  


What is the output of the program given below #include<stdio.h> main() { char i=0; for(;i>=0;i++) ; printf("%d\n",i); }

21 Answers   ADITI, Student, TCS,


What is the incorrect operator form following list(== , <> , >= , <=) and what is the reason for the answer?

0 Answers  


Categories