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...

Differentiate between range and xrange.

Answer Posted / hr@tgksolutions.com

Functionality-wise, xrange and range are nearly identical. Both of these let you create an integer list that you may use however you like. The only distinction between xrange and range is that x range returns an xrange object, whereas range returns a Python list object. Range will use as much memory as possible to produce your array of numbers, which can result in a memory error and crash your program. This is particularly true if you are working with a device that needs a lot of memory, like a phone. It has a memory issue and is a beast.

Is This Answer Correct ?    0 Yes 0 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

What are the 3 types of numbers in python?

848


Explain class __init__()?

845


What is MySQLdb?

928


Is python a single inheritance?

752


What is pip software in the python world?

835


What is meant by“call by value” in python?

810


What is docstring? How to define it?

893


What does means by split do in python?

985


what's wrong with import all?

767


How will you do debugging in python?

861


How does the ternary operator work in python?

835


How to determine the type of instance and inheritance in python?

829


How do you exit a python script?

841


How type casting is done in python?

874


Explain about indexing and slicing operation in sequences?

869