Namespace issues...
Aahz
aahz at pythoncraft.com
Sat Feb 14 10:28:48 EST 2004
More information about the Python-list mailing list
Sat Feb 14 10:28:48 EST 2004
- Previous message (by thread): Namespace issues...
- Next message (by thread): Table Oriented Programming
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]
In article <d1253dfc.0402140259.3b614b95 at posting.google.com>, cghost <phreacker at aol.com> wrote: > >i am very confused...why does the following script modify the global list "l": > >l=[] >def x(): > l.append("xyz") >x() >print l > >but the same script applied to a single variable doesnt..: > >l="moe" >def x(): > l+="howdy" >x() >print l http://starship.python.net/crew/mwh/hacks/objectthink.html -- Aahz (aahz at pythoncraft.com) <*> http://www.pythoncraft.com/ "Argue for your limitations, and sure enough they're yours." --Richard Bach
- Previous message (by thread): Namespace issues...
- Next message (by thread): Table Oriented Programming
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]
More information about the Python-list mailing list