adplus-dvertising
frame-decoration

Question

Which exception does the Iterators throw from their next() method when there are no more values to iterate, that work on finite collections ?

a.

ExitIteration

b.

AbortIteration

c.

Abort

d.

StopIteration

Posted under JavaScript

Answer: (d).StopIteration

Engage with the Community - Add Your Comment

Confused About the Answer? Ask for Details Here.

Know the Explanation? Add it Here.

Q. Which exception does the Iterators throw from their next() method when there are no more values to iterate, that work on finite collections ?