Open main menu
Home
Random
Recent changes
Special pages
Community portal
Preferences
About Wikipedia
Disclaimers
Incubator escapee wiki
Search
User menu
Talk
Dark mode
Contributions
Create account
Log in
Editing
C++ Standard Library
(section)
Warning:
You are not logged in. Your IP address will be publicly visible if you make any edits. If you
log in
or
create an account
, your edits will be attributed to your username, along with other benefits.
Anti-spam check. Do
not
fill this in!
===Containers=== {{See also|Standard Template Library}} Components that C++ programs may use for [[Container (abstract data type)|container data structures]]. {| class="wikitable" ! Name !! Description |- | {{code|<array>}} || Added in [[C++11]] and [[C++ Technical Report 1|TR1]]. Provides the container class template <code>[[array (C++)|std::array]]</code>, a container for a fixed sized array. |- | {{code|<bitset>}} || Provides the specialized container class <code>std::bitset</code>, a [[bit array]]. |- | {{code|<deque>}} || Provides the container class template <code>[[deque (C++)|std::deque]]</code>, a [[deque|double-ended queue]]. |- | {{code|<flat_map>}} || Added in [[C++23]]. Provides the container adapter class templates <code>std::flat_map</code> and <code>std::flat_multimap</code>. |- | {{code|<flat_set>}} || Added in [[C++23]]. Provides the container adapter class templates <code>std::flat_set</code> and <code>std::flat_multiset</code>. |- | {{code|<forward_list>}} || Added in [[C++11]] and [[C++ Technical Report 1|TR1]]. Provides the container class template <code>[[forward list (C++)|std::forward_list]]</code>, a [[Linked list|singly linked list]]. |- | {{code|<inplace_vector>}} || Added in [[C++26]]. Provides the class <code>std::inplace_vector</code>, analogous to <code>std::vector</code> with a fixed capacity defined at compile time. |- | {{code|<map>}} || Provides the container class templates <code>[[map (C++)|std::map]]</code> and <code>std::multimap</code>, sorted [[associative array]] and [[Multimap (data structure)|multimap]]. |- | {{code|<mdspan>}} || Added in [[C++23]]. Provides the class template <code>std::mdspan</code>, analogous to <code>std::span</code> but the view is multidimensional. |- | {{code|<queue>}} || Provides the container adapter class <code>std::queue</code>, a single-ended [[Queue (data structure)|queue]], and <code>std::priority_queue</code>, a [[priority queue]]. |- | {{code|<set>}} || Provides the container class templates <code>[[set (C++)|std::set]]</code> and <code>std::multiset</code>, sorted associative containers or [[Set (computer science)|set]]s. |- | {{code|<span>}} || Added in [[C++20]]. Provides the class template <code>std::span</code>, a non-owning view that refers to any contiguous range. |- | {{code|<stack>}} || Provides the container adapter class <code>[[stack (C++)|std::stack]]</code>, a [[Stack (data structure)|stack]]. |- | {{code|<unordered_map>}} || Added in [[C++11]] and [[C++ Technical Report 1|TR1]]. Provides the container class template <code>[[unordered map (C++)|std::unordered_map]]</code> and <code>std::unordered_multimap</code>, [[hash table]]s. |- | {{code|<unordered_set>}} || Added in [[C++11]] and [[C++ Technical Report 1|TR1]]. Provides the container class template <code>[[unordered set (C++)|std::unordered_set]]</code> and <code>std::unordered_multiset</code>. |- | {{code|<vector>}} || Provides the container class template <code>[[vector (C++)|std::vector]]</code>, a [[dynamic array]]. |}
Edit summary
(Briefly describe your changes)
By publishing changes, you agree to the
Terms of Use
, and you irrevocably agree to release your contribution under the
CC BY-SA 4.0 License
and the
GFDL
. You agree that a hyperlink or URL is sufficient attribution under the Creative Commons license.
Cancel
Editing help
(opens in new window)