I have a question regarding enhanced for loop in Java 5 and above. To use the it on an object, what is the requirement for that object?
should be an Array, should implement Collection interface, should implement Iterator or should implement Iterable ??
I have been using it on arrays only.