This issue tracker has been migrated to GitHub, and is currently read-only.
For more information, see the GitHub FAQs in the Python's Developer Guide.

classification
Title: example code not working
Type: Stage:
Components: Documentation Versions: Python 2.3
process
Status: closed Resolution: not a bug
Dependencies: Superseder:
Assigned To: Nosy List: rhettinger, zivkovicperica
Priority: normal Keywords:

Created on 2004-12-19 16:35 by zivkovicperica, last changed 2022-04-11 14:56 by admin. This issue is now closed.

Messages (2)
msg23773 - (view) Author: perica (zivkovicperica) Date: 2004-12-19 16:35
in chapter "9.11 Generator Expressions" in "Python
Tutorial" this example is not working:

>>> sum(i*i for i in range(10))                 # sum
of squares
285

I'm using Python 2.3.4 (GCC 3.4.2) on FreeBSD 5.3 

msg23774 - (view) Author: Raymond Hettinger (rhettinger) * (Python committer) Date: 2004-12-19 18:27
Logged In: YES 
user_id=80475

It looks like you have a Python 2.4 tutorial in-hand but are
working with an old version of python, 2.3.4 which did not
have generator expressions.

Here is a link to the tutorial that matches the version on
your system (note it does not have a section 9.11):

http://www.python.org/doc/2.3.4/tut/tut.html

History
Date User Action Args
2022-04-11 14:56:08adminsetgithub: 41343
2004-12-19 16:35:38zivkovicpericacreate