The Iterator Pattern is a behavioral pattern.
The iterator design pattern gives you the ability to use different types of iterators to iterate through different types of complex data structures.
- When you want to use x types of iterators to loop through a complex data structure.
- From exposing the iteration its internal implementation (see Main.java).