What is the difference between Class and Structure?
Answer Posted / nikhil jain
Structures are value types; classes are reference types.
Structures use stack allocation; classes use heap
allocation.
A structure must have at least one nonshared variable or
event member; a
class can be completely empty.
| Is This Answer Correct ? | 4 Yes | 9 No |
Post New Answer View All Answers
Can class objects be passed as function arguments?
What is == in programming?
What is the keyword auto for?
Define what is constructor?
What is istream and ostream in c++?
What are put and get pointers?
Define the operators that can be used with a pointer.
What is c++ code?
What is c++ and its features?
Is atoi safe?
Is oops and c++ same?
Which software is used to run c++ program?
What does extern mean in a function declaration in c++?
How many namespaces are there in c++?
What is the latest c++ standard?