class abc:
list = ['a', 'b', 'c']
def printInfo(arg):
x = 0
while x < len(list): # <== this as you know will yield an error
print type[x] # TypeError: len() of unsized object
x = x + 1 # I know it works if I say len(abc.list)
But isn't 'list' within scope of the class definition??
Must I use the 'abc.list' notation within the class definition
or am I missing something?
Sorry if this is very obvious!!
Dave
==========================================
David Richards
The Aaron Copland School of Music
at Queens College
E-mail: richards@aaron.music.qc.edu
Voice : 1-(718)-997-3874
==========================================