Difference Between Iterator And Enumeration
What is Iterator? An Iterator is an object that enables a programmer to traverse a container, particularly lists. It is used with most of the collection classes like ArrayList, LinkedList, HashSet, TreeMap, TreeSet etc but iterators cannot be used with legacy classes like Vectors, Stack, HashTables etc. Iterator allows to remove elements from the underlying … Read more