Chapter 18: Problem 16
What element does the remove method (in the Iterator interface) remove?
Short Answer
Expert verified
Answer: The remove() method in the Iterator interface removes the last element returned by the iterator's next() method. It can be called only once per call to the next() method, and calling it twice in a row without calling next() in between will result in an IllegalStateException.