Algorithmic learning: STL and basic data structures

STL Container vector Stack queue linked list set map sort function next_permulation function container 1. Sequential containers: vector,list,deque,queue,priority_queue,stack, etc. 2. Associative containers: set, multiset, map, multimap, etc. vector vector containers can hold any type of object: functionExampleExplainassignmenta.push_back( ...

Added by elementaluk on Fri, 15 Oct 2021 19:17:59 +0300

Experience in using stl container

1. The associated container implements its own comparison type We often define a container. vector<int> vec; In fact, this is the abbreviation of the following function. vector<int, less<int>> vec; vector<int, less<int>, allocator<int>> vec; It is only the default. The default size comparison function ...

Added by speckledapple on Fri, 08 Oct 2021 07:40:18 +0300