What is the difference between Class and Structure?
Answer Posted / vandana mishra
Class is much broader,real world applicable 1-1-1: concept whereas structure is a primitive concept with poor internal organisation.
2: structure contains only data while class bind both data & member functions.
3: class provide data hiding,inheritance etc but structure didn't.
4: if we not define constructor in class there constructor automaticly invoke but in structure it does not happen automaticly.
| Is This Answer Correct ? | 0 Yes | 0 No |
Post New Answer View All Answers
What is anonymous object in c++?
what you know about c++?
What is overloading unary operator?
How are the features of c++ different from c?
What is an operator function? Describe the function of an operator function?
Are php strings immutable?
Can I learn c++ without knowing c?
What are formatting flags in ios class?
What is the this pointer?
What is the difference between a "copy constructor" and an "assignment operator" in C++?
Write about c++ storage classes?
What are the advantages of using a pointer?
What are friend functions in C++?
If a function doesn’t return a value, how do you declare the function?
A mXn matrix is given and rows and column are sorted as shown below.Write a function that search a desired entered no in the matrix .with minimum complexity 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16