Discussion :: Objects and Collections - Pointing out the correct statements (Q.No.7)
|Bryan Pack said: (Apr 28, 2016)|
|The answer could be either 'B' OR 'C' depending on the version of Java.
Iterator now has:
default void for EachRemaining(Consumer<? super E> action) in addition to boolean hasNext(), E next() & default void remove().
|Ford Prefect said: (Jul 17, 2016)|
|It's 2016, Java 7 is EOL already, so the Iterator interface has four methods, therefore C is correct, not B.|
Post your comments here:
Email : (optional)
» Your comments will be displayed only after manual approval.