What is the difference between Class and Structure?

Answer Posted / vinod

The difference between a class and a structure is that, by
default, all of the members of a class are private and also private,public and protected but in structure by
default, all of the members of a structure are public.

Is This Answer Correct ?    5 Yes 3 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

What is the fastest c++ compiler?

582


What is lazy initialization in c++?

654


What is one dimensional array in c++?

577


How does work in c++?

594


Differentiate between an inspector and a mutator ?

703






What is enum class in c++?

706


What is an adaptor class in c++?

598


What is the history of c++?

555


Explain the difference between overloading and overriding?

609


Is recursion allowed in inline functions?

607


How java is different from c and c++?

637


What things would you remember while making an interface?

561


What are c++ storage classes?

618


What is the difference between the functions memmove() and memcpy()?

628


Difference between overloading vs. Overriding

588