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

Answer Posted / shaan

in 1970's and 1980's C is a high level language,so For
complexity later C++ introduced by bjarne stroustrip at
1990, The Main Difference between c and C++ are ,C++
supports OOPS concept By sharing Global and local variable
from a class ,and C++ supports Class and object concept, So
to face real time Entity C extended to c++ .

Is This Answer Correct ?    0 Yes 0 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

Why is there no multiple inheritance?

571


What is the renewal class?

2170


What is polymorphism and why is it important?

562


Question: Write a program that prints a paycheck. Ask the program user for the name of the employee, the hourly rate, and the number of hours worked. If the number of hours exceeds 40, the employee is paid “time and a half”, that is, 150 percent of the hourly rate on the hours exceeding 40. Be sure to use stepwi se refine ment and break your solution into several functions. Use the int_name function to print the dollar amount of the check.

699


Why is abstraction used?

612






What is polymorphism and example?

593


What are the 4 pillars of oop?

674


hi, this is raju,iam studying b.tech 2nd year,iam want know about group1 and group2 details, and we can studying without going to any instutions? please help me.

1543


#include #include #include #include void insert(struct btreenode **, int); void inorder(struct btreenode *); struct btreenode { struct btreenode *leftchild; struct btreenode *rightchild; int data; }; main() { struct btreenode *bt; bt=(struct btreenode *)NULL; int req,i=1,num; clrscr(); printf("Enter number of nodes"); scanf("%d",&req); while(i<=req) { printf("Enter element"); scanf("%d",&num); insert(&bt,num); i++; } inorder(bt); } void insert(struct btreenode **sr, int num) { if(*sr==NULL) { *sr=(struct btreenode *)malloc (sizeof(struct btreenode)); (*sr)->leftchild=(struct btreenode *)NULL; (*sr)->rightchild=(struct btreenode *)NULL; (*sr)->data=num; return; } else { if(num < (*sr)->data) insert(&(*sr)->leftchild,num); else insert(&(*sr)->rightchild,num); } return; } void inorder(struct btreenode *sr) { if(sr!=(struct btreenode *)NULL) { inorder(sr->leftchild); printf("\n %d",sr->data); inorder(sr->rightchild); } else return; } please Modify the given program and add two methods for post order and pre order traversals.

3256


Can an interface inherit a class?

565


What is the difference between a constructor and a destructor?

615


What does sksksk mean in text slang?

1537


What is polymorphism programming?

605


• What are the desirable attributes for memory managment?

1728


Which is not an object oriented programming language?

544