Container constructors & destructors
Syntax:
#include <set> container(); container( const container& c ); ~container(); Every multiset has a default constructor, copy constructor, and destructor. The default constructor takes no arguments, creates a new instance of that multiset, and runs in constant time. The default copy constructor runs in linear time and can be used to create a new multiset that is a copy of the given multiset c. The default destructor is called when the multiset should be destroyed. For example, the following code creates a pointer to a vector of integers and then uses the default multiset constructor to allocate a memory for a new vector: vector<int>* v; v = new vector<int>(); |