O'Reilly logo

The C++ Programming Language, Fourth Edition by Bjarne Stroustrup

Stay ahead with the world's most comprehensive technology and business learning platform.

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, tutorials, and more.

Start Free Trial

No credit card required

33. STL Iterators

The reason that STL containers and algorithms work so well together is that they know nothing of each other.

– Alex Stepanov

Introduction

Iterator Model

Iterator Categories; Iterator Traits; Iterator Operations

Iterator Adaptors

Reverse Iterators; Insert Iterators; Move Iterator

Range Access Functions

Function Objects

Function Adaptors

bind(); mem_fn(); function

Advice

33.1. Introduction

This chapter presents the STL iterators and utilities, notably standard-library function objects. The STL consists of the iterator, container, algorithm, and function object parts of the standard library. The rest of the STL is presented in Chapter 31 and Chapter 32.

Iterators are the glue that ties standard-library algorithms ...

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, interactive tutorials, and more.

Start Free Trial

No credit card required