What is a container class? What are the types of container classes?
Answer / subham chaudhary
A container class is a class that is used to hold objects in memory or external storage. A container class acts as a generic holder. A container class has a predefined behavior and a well-known interface. A container class is a supporting class whose purpose is to hide the topology used for maintaining the list of objects in memory. When a container class contains a group of mixed objects, the container is called a heterogeneous container; when the container is holding a group of objects that are all the same, the container is called a homogeneous container.
| Is This Answer Correct ? | 0 Yes | 0 No |
class Foo { public: Foo(int i) { } }; class Bar : virtual Foo { public: Bar() { } }; Bar b; Referring to the above code, when the object 'b' is defined, a compiler error will occur. What action fixes the compiler error? a) Adding a virtual destructor to the class Bar b) Adding a constructor to Bar which takes an int parameter c) Adding "Foo()" to the Bar constructor d) Adding a copy constructor to the class Foo e) Adding "Foo(0)" to the Bar::Bar initializer list
Explain rethrowing exceptions with an example?
What do you mean by storage classes?
Can I create my own functions in c++?
How to access a variable of the structure?
How to avoid a class from instantiation?
Explain the extern storage classes in c++.
Difference between Overloading and Overriding?
35 Answers Appnetix Techno, GameLoft, HP, IBM, NIIT, Rohde and Schwarz,
Eplain extern keyword?
What is the role of copy constructor in copying of thrown objects?
How to stop conversions among objects?
How c functions prevents rework and therefore saves the programers time as wel as length of the code ?