Search
 
SCRIPT & CODE EXAMPLE
 
CODE EXAMPLE FOR PYTHON

Python Iterator

fruits = ["apples", "bananas", "cherries", "pears", "plums"]
fruitIterator = iter(fruits);
print(next(fruitIterator))
print(next(fruitIterator))
print(next(fruitIterator))
 
PREVIOUS NEXT
Tagged: #Python #Iterator
ADD COMMENT
Topic
Name
7+7 =