Array
The built-in array is packaged, and an array is formed after bundling common operations. The advantage of array is that it is almost identical to the built-in array in time-space efficiency, but it is easier to use than built-in arrays. The size function replaces sizeof (ARR)/sizeof (arr[0]), and the back function replaces the arr[sizeof (arr)/sizeof (Arr[0]-1],array can also swap and compare. The disadvantage of array is the fixed size.
Vector
Container sizes can be dynamically increased and cannot be reduced dynamically. Vectors support subscript access, which is second only to the built-in arrays and array. Vector in the tail of the increase, delete operation is very efficient, other locations are very inefficient. In essence, the vector is a contiguous memory, and when the memory size is not enough, the vector will request a larger chunk of memory to replace the old memory. The advantages and disadvantages of vectors are related to their nature.
Deque
Container size can be dynamically increased and reduced. Deque supports subscript access, but the slowest access. Deque in the head, tail of the increase, removal operation is very efficient, other locations are low. The advantage and disadvantage of deque is that it is essentially multiple contiguous memory, not a block.
List
List is essentially a doubly linked list, so subscript access is not supported. List in any position insertion, deletion is a constant time, in addition to the beginning and tail, more efficient than vector, deque.
Forward_list
Forward_list is essentially a one-way linked list, designed to save space (even the size function is saved). Forward_list does not support subscript access, the operation is also different from other containers, vector, List of INSERT, erase operation is to delete iterator refers to the element, and Forward_ The list is the element that is removed after the element that iterator refers to.
Set
Associative containers, set corresponding to the concept of a set, the advantage is that it can be quickly found.
Map
Associative containers, map corresponding to the concept of a dictionary table, the advantage is that it can be quickly found.
Containers for the C + + standard library