Golgappa.net | Golgappa.org | BagIndia.net | BodyIndia.Com | CabIndia.net | CarsBikes.net | CarsBikes.org | CashIndia.net | ConsumerIndia.net | CookingIndia.net | DataIndia.net | DealIndia.net | EmailIndia.net | FirstTablet.com | FirstTourist.com | ForsaleIndia.net | IndiaBody.Com | IndiaCab.net | IndiaCash.net | IndiaModel.net | KidForum.net | OfficeIndia.net | PaysIndia.com | RestaurantIndia.net | RestaurantsIndia.net | SaleForum.net | SellForum.net | SoldIndia.com | StarIndia.net | TomatoCab.com | TomatoCabs.com | TownIndia.com
Interested to Buy Any Domain ? << Click Here >> for more details...

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

Answer Posted / rsn

Hello Shivani,

I think both struct and class in C++ are quite the same
except for the fact that, members in struct are public by
default whereas they are private for class.
Moreover struct also supports inheritance,polymorphism
etc...etc...

Is This Answer Correct ?    14 Yes 0 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

How can you quickly find the number of elements stored in a dynamic array? Why is it difficult to store linked list in an array?

1044


What are keywords in c++?

1109


What are the effects after calling the delete this operator ?

1070


How the memory management in vectors are being done. What happens when the heap memory is full, and how do you handle it ?

2322


What are the new features that iso/ansi c++ has added to original c++ specifications?

1155


Does there exist any way to make the command line arguments available to other functions without passing them as arguments to the function?

1260


What are libraries in c++?

1080


What does n mean in c++?

1178


What happens when the extern "c" char func (char*,waste) executes?

1096


Evaluate !(1&&1||1&&0) a) Error b) False c) True

1219


Explain how the virtual base class is different from the conventional base classes of the opps.

1180


What is a storage class used in c++?

1097


What is a far pointer? where we use it?

1085


How can you link a c++ program to c functions?

1113


Write about the retrieval of n number of objects during the process of delete[]p?

1029