On Aug 21, 11:52 am, "[EMAIL PROTECTED]" <[EMAIL PROTECTED]> wrote: > I tryed your code and got an error message #I use Wing IDE: > Python 2.2.3 (#42, May 30 2003, 18:12:08) [MSC 32 bit (Intel)] > Type "help", "copyright", "credits" or "license" for more information. > > Evaluating lines 1-16 from truckStops.py > <string>:7: Warning: 'yield' will become a reserved keyword in the > future > Could not execute because an error occurred: > invalid syntax: <string>, line 7, pos 19: > yield stops, wage
Python 2.2.3 is three versions behind. Generators only work in 2.2 by saying: from __future__ import generators And by default in anything from 2.3 on. Fred -- http://mail.python.org/mailman/listinfo/python-list