Multiple choice

Find out the true statements.

i. Iterator is used to obtain the element in the bi-directional direction. ii. Iterator is used to obtain the elements in the forward direction only. iii. List Iterator is used to obtain the element in the bi-directional direction. iv. List Iterator is used to obtain the element in the forward direction only.

  1. i. and iii. are true

  2. i. and iv. are true

  3. ii. and iii. are true

  4. ii. and iv. are true.

Reveal answer Fill a bubble to check yourself
C Correct answer
Explanation

This answer is correct. Iterator interface is used to obtain elements from the collection in forward direction only. ListIterator is used to obtain elements from the collection in bi-directional direction only.