Container Adapters

This chapter explains some variations on the containers you saw in the previous chapter that the STL provides. These define simpler interfaces to a sequence container that you use in particular circumstances. You’ll also be seeing more about how you can store pointers in a container. In this chapter you’ll learn:

  • What a container adapter is.
  • How you define a stack and when and how you use it.
  • How you define and use a queue.
  • How to create and use a priority queue and how it differs from a queue.
  • What a heap is, how you create and use a heap, and how a heap relates to a priority queue.
  • The benefits of storing pointers ...

Get Using the C++ Standard Template Libraries now with O’Reilly online learning.

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