0 votes
in C Plus Plus by
What is an Iterator class?

1 Answer

0 votes
by

In C++ a container class is a collection of different objects.

If we need to traverse through this collection of objects, we cannot do it using simple index variables. Hence, we have a special class in STL called an Iterator class which can be used to step through the contents of the container class.

The various categories of iterators include input iterators, output iterators, forward iterators, bidirectional iterators, random access, etc.

Related questions

+2 votes
asked Jun 19, 2019 in C Plus Plus by anonymous
0 votes
asked Jun 15, 2020 in C Plus Plus by Robindeniel
+1 vote
asked Jul 16, 2019 in C Plus Plus by Indian
...