<deque>
The <deque>
header is one of the standard container template headers.
It declares the deque
class template
and a few global functions that operate on deque
objects.
A deque, short for double-ended queue, is similar to a vector, but the performance is constant when adding to or removing from the collection at the beginning and at the end.
If you need a vector of bool
that behaves as a normal C++ container, you should use deque<bool>
instead of vector<bool>
. See <vector>
later in this chapter for an
explanation.
See Chapter 10 for information about containers in general.
Get C++ In a Nutshell now with the O’Reilly learning platform.
O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.