1.

Which design pattern represents a way to access all the objects in a collection?(a) Iterator pattern(b) Facade pattern(c) Builder pattern(d) Bridge patternThe question was asked in an international level competition.My question is from Design Patterns in chapter Java Beans & JDBC of Java

Answer»

Right option is (a) ITERATOR pattern

The EXPLANATION is: Iterator pattern represents a way to ACCESS the elements of a collection object in sequential manner without the need to know its UNDERLYING REPRESENTATION.



Discussion

No Comment Found

Related InterviewSolutions