[Tutor] Your dog Scope bit me!
Mon, 20 Aug 2001 20:27:29 -0700
On Mon, 20 Aug 2001 23:16:45 -0400 (EDT), <email@example.com> wrote
about [Tutor] Your dog Scope bit me!:
: """retrieves upc dictionary as upc"""
: import pickle
: print "UPC Dictionary retrieved"
:I'm assuming I have a scope problem. Guess I don't understand all I
:should about scopes. How do I run this from an interactive session so
:that I'm able to use the dictionary?
How about adding a last line to your function:
And then call it in your main code like this:
dict = get_upc()