[Tutor] Store Class in Tuple Before Defining it ...
Alan Gauld
alan.gauld at btinternet.com
Sat Aug 29 01:32:53 CEST 2009
"Damon Timm" <damontimm at gmail.com> wrote
> Anyhow, I would like to have a tuple defined at the beginning of my
> code that includes classes *before* they are defined ... as such (this
> is on-the-fly-hack-code just for demonstrating my question):
See another recent thread - you can't do it.
What you could do is put your classes in another module and
then import that module. Or you could put the tuple initialisation
into a function.
But its probably easiest to just move the definition
to the bottom of the file...
HTH,
--
Alan Gauld
Author of the Learn to Program web site
http://www.alan-g.me.uk/
More information about the Tutor
mailing list