On 9/7/2010 6:00 AM, BartC wrote:

Why should it? But if you want it, you can do it:

xrange = range

There, that wasn't hard, was it?

I think I just learned more about Python than from months of reading this
group.

So 'range' is just a class like any other. And that a class is something
you
can blithely copy from one variable to another.

There is no copying of the class object. A new name is associated with the object. Any object can be given any number of names (aliases) that refer to the one and same object.

--
Terry Jan Reedy

--
http://mail.python.org/mailman/listinfo/python-list

Reply via email to