Containers Overview

Image

The sequence containers represent linear data structures (i.e., all of their elements are conceptually “lined up in a row”), such as arrays, vectors and linked lists. Associative containers are nonlinear data structures that typically can locate elements stored in the containers quickly. Such containers can store sets of values or key–value pairs. As of C++11, the keys in associative containers are immutable (they cannot be modified). The sequence containers and associative containers are collectively referred to as the first-class containers. Stacks and queues are typically constrained versions of sequence containers. For ...

Get C++11 for Programmers, Second Edition now with O’Reilly online learning.

O’Reilly members experience live online training, plus books, videos, and digital content from 200+ publishers.