For example, a list container includes functions that insert, delete, and merge elements. A stack includes functions that push and pop values. Algorithms Algorithms act on containers. They provide the means by which you will manipulate the contents of containers. Their capabilities include initialization, sorting, searching, and transforming the contents of containers.
Many algorithms operate on a range of elements within a container.
Iterators Iterators are objects that act more or less like pointers. They give you the ability to cycle through the contents of a container in much the same way that you would use a pointer to cycle through an array. Elements may be accessed randomly. Bidirectional Store and retrieve values. Forward and backward moving.