Q. Which interface is used to iterate over a collection?
Solution:
The Iterator interface provides methods like hasNext() and next() to traverse a collection.
Get Question Bank
Strengthen Your Practice with our comprehensive question bank.
The Iterator interface provides methods like hasNext() and next() to traverse a collection.
Strengthen Your Practice with our comprehensive question bank.