Lesson 4.1

Cards (8)

  • Associative containers
    • Set: Collection of unique keys, sorted by keys
    • Map: Collection of key-value pairs, sorted by keys, keys are unique
    • multiset: Collection of keys, sorted by keys
    • multimap: Collection of key-value pairs, sorted by keys
  • Sequence containers
    • array
    • vector
    • deque
    • forward_list
    • list
  • Container adapters
    • stack: Adapts a container to provide stack (LIFO data structure)
    • queue: Adapts a container to provide queue (FIFO data structure)
    • priority_queue: Adapts a container to provide priority queue
  • Container
    • Manages storage space for its elements
    • Provides member functions to access elements, either directly or through iterators
  • Sequence containers
    Data structures that can be accessed sequentially
  • Container
    1. Holder object that stores a collection of other objects (its elements)
    2. Implemented as class templates, allowing flexibility in the types supported as elements
  • Container adapters
    Provide a different interface for sequential containers
  • Associative containers
    Sorted data structures that can be quickly searched (O(log n) complexity)