Golgappa.net | Golgappa.org | BagIndia.net | BodyIndia.Com | CabIndia.net | CarsBikes.net | CarsBikes.org | CashIndia.net | ConsumerIndia.net | CookingIndia.net | DataIndia.net | DealIndia.net | EmailIndia.net | FirstTablet.com | FirstTourist.com | ForsaleIndia.net | IndiaBody.Com | IndiaCab.net | IndiaCash.net | IndiaModel.net | KidForum.net | OfficeIndia.net | PaysIndia.com | RestaurantIndia.net | RestaurantsIndia.net | SaleForum.net | SellForum.net | SoldIndia.com | StarIndia.net | TomatoCab.com | TomatoCabs.com | TownIndia.com
Interested to Buy Any Domain ? << Click Here >> for more details...

What are python iterators?

Answer Posted / glibwaresoftsolutions

An object that lets you go through a collection's items (such lists, tuples, or dictionaries) one at a time is called an iterator in Python. An iterator implements two methods: __next__(), which returns the subsequent item in the sequence and raises StopIteration when the sequence is exhausted, and __iter__(), which returns the iterator object itself.

Is This Answer Correct ?    0 Yes 0 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

Is python is better than java?

882


How to reload a python module?

999


What is pip and when it is used ?

902


What is the python keyword "with" used for?

953


How does for loop and while loop differ in python and when do you choose to use them?

894


How will you verify different flags at once?

877


Why should we hire you examples?

888


Tell us what is python? What are the benefits of using python? What do you understand of pep 8?

991


Why anaconda is used for python?

919


What is the zip() function in python?

998


What are key features of python?

883


Explain me inheritance in python with an example?

994


How can I force division to be floating point in python?

845


Give an example for join() and split() funcitons

991


How do I put python to sleep?

929