boolean hasMoreElements( ) return true while there are still more elements to extract - Wrapper classes
Q. Which method when implemented must return true while there are still more elements to extract, and false when all the elements have been enumerated?
- Published on 19 Oct 15a. Object nextElement( )
b. boolean hasMoreElements( )
c. Both A & B
d. None of the above
ANSWER: boolean hasMoreElements( )