[Tutor] Print text position problems when using triple quotes
Kent Johnson
kent37 at tds.net
Thu Feb 24 20:23:28 CET 2005
Bill Mill wrote:
>>class foo:
>> def bar(self):
>
>
> Sorry, I forgot that if it's in the module, you should declare prompt1
> as global by using "global prompt1" right here.
>
>
>> print prompt1 % (var1, var2, var3)
No, you only need the global statement if you want to assign to a global variable. Read-only
reference will work without the global.
Kent
More information about the Tutor
mailing list