What are the differences between a struct and a class in
C++?

Answer Posted / ramesh kasi

The only difference is related to the default access
specifier.
The members of a structure have public access by default.
The members of a calss have private access by default.

Is This Answer Correct ?    3 Yes 1 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

What are abstract data types in c++?

533


How would perform Pattern Matching in C++?

656


Is turbo c++ free?

619


Is it possible to have a recursive inline function in c++?

552


What is a down cast?

611






What do you mean by function pointer?

593


Give 10 points of differences between C & C++.

623


an operation between an integer and real always yeilds a) integer result b) real result c) float result

710


Is string an object in c++?

656


Explain rtti.

592


What is the role of C++ shorthand's?

677


Describe private, protected and public?

600


What is std namespace in c++?

718


Who made c++?

609


What is runtime errors c++?

572