If you're just going to be using numbers as dictionary keys, it might
be simpler just to use a list structure. Dictionaries don't preserve
order, so you'd need to write extra code if you ever need to iterate
over it in order. Since your code increments field everytime it gets a
new record you can just use it as a list index and things should be
fine. Of course you might have your own reasons for using a dict, so
it's up to you.
-- 
The ByteBaker :
http://www.bytebaker.com
_______________________________________________
Tutor maillist  -  Tutor@python.org
http://mail.python.org/mailman/listinfo/tutor

Reply via email to