Explain container class.



Explain container class...

Answer / Shiv Kumar Choudhary

A container class in C++ is a generic programming concept that allows the implementation of data structures like vectors, lists, sets, and maps. These classes provide methods to add, remove, access, and manipulate elements efficiently. They offer flexibility by allowing different types of data (like integers, strings, or custom objects) to be stored in them.

Is This Answer Correct ?    0 Yes 0 No

Post New Answer

More C++ General Interview Questions

Why would you use pointers in c++?

1 Answers  


What is a set in c++?

1 Answers  


What is a friend function in c++?

3 Answers  


In a class, there is a reference or pointer of an object of another class embedded, and the memory is either allocated or assigned to the new object created for this class. In the constructor, parameters are passed to initialize the data members and the embedded object reference to get inialized. What measures or design change should be advised for proper destruction and avioding memory leaks, getting pointers dangling for the embedded object memory allocation? Please suggest.

5 Answers   GE,


i want to know how to copy arrary without using any method or function. I have tried the below using System; class e4 { static void Main(string[] args) { int a,b; int[ ] m= new int[5]; int[ ] n= new int[5]; for(a=0;a<=4;a++) { Console.WriteLine("enter any value"); m[a]=Convert.ToInt32(Console.ReadLine()); m[a]=n[a]; } for(b=0;b<=4;b++) { Console.WriteLine(n[b]); } } } but it will give wrong result can anyone solve this problem

1 Answers   Reliance,


Are strings immutable in c++?

1 Answers  


What is the purpose of templates in c++?

1 Answers  


What are manipulators in c++ with example?

1 Answers  


Write a short code using c++ to print out all odd number from 1 to 100 using a for loop

1 Answers  


What is helper in c++?

1 Answers  


what is the emaning of '#include" "'?

5 Answers  


What are references in c++? What is a local reference?

1 Answers  


Categories