In this chapter we've learned the following: A container manages the ownership of a collection of elements. STL containers are always class templates parameterized on the element type, and sometimes on other relevant parameters as well. Every container except std::array<T, N> can be parameterized by an allocator type to specify the manner in which it allocates and deallocates memory. Containers that use comparison can be parameterized by a comparator type. Consider using transparent comparator types such as std::less<> instead of homogeneous comparators.
When using std::vector, watch out for reallocation and address invalidation. When using most container types, watch out for iterator invalidation.
The standard library's philosophy is to support no operation that is naturally inefficient (such as vector::push_front); and to support any operation that...