What is the difference between Class and Structure?

Answer Posted / rohit patil

Syntax of class
class class_name
{
variable_declaration
function_declaration
};

syntax of structure
struct struc_name
{
variable declaration
};

Is This Answer Correct ?    2 Yes 2 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

Which is best ide for c++?

572


Is c++ a high level language?

560


Do you need a main function in c++?

561


Describe friend function & its advantages.

720


what is oops and list its features in c++?

554






To which numbering system can the binary number 1101100100111100 be easily converted to?

609


Write a program to show polymorphism in C++?

636


What is encapsulation in C++? Give an example.

590


Is c++ harder than java?

572


What is using namespace std in c++?

614


What's the "software peter principleā€?

627


What are arithmetic operators?

546


How do you print a string on the printer?

584


Can circle be called an ellipse?

640


What is the need of a destructor?

643