On Thu, Jul 19, 2007 at 10:57:23AM -0600, Chris Friesen wrote:
> Dave Hall wrote:
> >On Thu, Jul 19, 2007 at 08:48:55AM -0700, Steven Kurylo wrote:
>
> >> "all variables found outside of the innermost scope are read-only
> >>(an attempt to write to such a variable will simply create a new local
> >>variable in the innermost scope, leaving the identically named outer
> >>variable unchanged)."
>
> I have zero python experience, so this seems odd. Does this mean that
> there's no such thing as a global variable?
There is, but unless you declare it as global in your method it will
be read-only. If you assign to it without declaring it global, you
are then working on a local variable and the global one will remain
unchanged.
Perhaps a little odd, but its not a problem once you are used to it.
-- Jason
Received on Thu Jul 19 11:01:42 2007
This archive was generated by hypermail 2.1.8 : Thu Jul 19 2007 - 11:01:45 CST