On 03/04/2015 09:11 PM, boB Stepp wrote:
On Wed, Mar 4, 2015 at 7:53 PM, Phil <phil_...@bigpond.com> wrote:
I hope this is not another embarrassingly obvious answer to a simple
question.

Python 3, under Kubuntu.

xrange() fails whereas range() is accepted. Could this be an installation
problem?
etc

This may fall into the obvious answer. ~(:>))

My Python reference says that the xrange function was discontinued in
Python 3, which you are using.

"In Python 3.x, the original range() function is changed to return an
iterable instead of producing a result in memory, and thus subsumes
and [sic?] Python 2.x's xrange(), which is removed." -- Python Pocket
Reference, 5th ed., by Mark Lutz.


And the other half of the answer is that your IDLE is apparently using the Python 2 interpreter, in which print is defined differently.


--
DaveA
_______________________________________________
Tutor maillist  -  Tutor@python.org
To unsubscribe or change subscription options:
https://mail.python.org/mailman/listinfo/tutor

Reply via email to