whats the difference between c and c++

Answer Posted / vivek

1>c is an procedural language and c++ is an object oriented.
2>c uses a TOP DOWN approach and c++ BOTTOM UP.
3>c++ introduces the idea of Data hiding using class..shere
in c there is no such facility for that purpose
4>c++ introduce the concept of the message passing with that
objects can communicate.
5>c++ has the inheritence, using it we can reuse our code.
6>Using polymorphism of c++ we can achieve the overloading
of operator and functions, but it is not possible in c.

there may be more difference on this but these are the main..

Is This Answer Correct ?    19 Yes 0 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

Is html an oop?

571


What is difference between polymorphism and inheritance?

611


What is polymorphism programming?

593


Why we use classes in oop?

571


What is difference between inheritance and polymorphism?

560






what is graphics

2003


What is difference between data abstraction and encapsulation?

610


Why do we use polymorphism in oops?

573


Get me an image implementation program.

1553


assume the program must insert 4 elements from the key board and then do the following programs.sequential search(search one of the elements),using insertion sort(sort the element) and using selection sort(sort the element).

1662


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.

688


What is abstraction in oops with example?

765


class CTest { public: void someMethod() { int nCount = 0; cout << "This is some method --> " << nCount; } }; int main() { CTest *pctest; pctest->someMethod(); return 0; } It will executes the someMethod() and displays the value too. how is it possible with our creating memory for the class . i think iam not creating object for the class. Thanks in Advance... Prakash

1685


What is object-oriented programming? Webopedia definition

715


What are the benefits of polymorphism?

614