What are the differences between a struct and a class in
C++?
Answer Posted / supriya
Memory is alloated on Stack using Structure whereas in class its heap , that is it wont be stored at an contagious memory location.
Is This Answer Correct ? | 0 Yes | 0 No |
Post New Answer View All Answers
What is the use of main function in c++?
What is c++ try block?
Why c++ is better than c language?
Difference between overloading vs. Overriding
What is insertion sorting?
What is code reusability in c++?
What are the advantages of using friend classes?
Given the following seqment of code containing a group of nested if instructions: y = 9; if ((x==3) || (x == 5)) y++; else if (x == 2) y *= 2; else if (x == ) y-= 7; else y = 8; if the value of x is 4 before the nested IFs are executed, what is the value of y after the nested IFs are executed?
What are the types of container classes?
What are disadvantages of pointers?
How can you create a virtual copy constructor?
What is format for defining a structure?
What is runtime polymorphism in c++?
Which format specifier is used for printing a pointer value?
Why c++ is created?