global name 'self' is not defined - noob trying to learn
mark.seagoe at gmail.com
mark.seagoe at gmail.com
Mon Mar 30 15:01:53 EDT 2009
On Mar 30, 11:53 am, Dave Angel <da... at ieee.org> wrote:
> After taking out the class myclass stuff, the code worked for me in
> Python 2.6.1, through the cat line. Could you please tell us what
> version of Python you're running this on?
>
> import sys
> print "Python version: ", sys.version
>
> yielded (on my machine)
> Python version: 2.6.1 (r261:67517, Dec 4 2008, 16:51:00) [MSC v.1500
> 32 bit (Intel)]
>
> (There are two typos in Test 3, and in Test 4 you seem to be treating
> this object like a list.)
>
Python version: 2.5.1 (r251:54863, Apr 18 2007, 08:51:08)
(Thought it was 2.5.3, sorry).
More information about the Python-list
mailing list