[Tutor] List of class instances

Jan Eden lists at janeden.org
Tue Sep 20 12:58:08 CEST 2005


Hi,

Orri Ganel wrote on 20.09.2005:

>As a side-note, unless you're okay with only being able to access
>those instance variables through the fields list (ie fields[0],
>fields[1], fields[2]), you may want to actually name them first.

Yes, I am fine with that - I actually prefer to have a sorted list instead of a dictionary. I'll always access them like

for field in fields:
    ...

Thanks,

Jan
-- 
I'd never join any club that would have the likes of me as a member. - Groucho Marx


More information about the Tutor mailing list