On the STL [set] and [] muliset

 

I is limited, at the problem is not the solution, a lot of understanding

Thank you for watching this konjac

 

Recommended blog 1- how to use the set and muliset: Portal

 

 

Recommended blog 2- On muliset role : Portal

 

set the value of each element are unique ,

 

The system can moreover automatically sorted values of the elements to be noted that the value of the number of elements in the set can not be directly changed .

 

multiset is <set> a useful library type,

 

It can be seen as a sequence, to insert a number, to delete a number can be in time O (logn) is completed,

 

And he can always ensure the number in the sequence is ordered , and the sequence may be repeated a number exists .

 

the difference is that the set of muliset whether to allow duplicate elements , other uses are very similar

 

 

Guess you like

Origin www.cnblogs.com/nlyzl/p/11830465.html