dict.items() vs dict.iteritems and similar questions

skip at pobox.com skip at pobox.com
Wed Mar 14 14:53:30 EDT 2007


    >> When is it appropriate to use dict.items() vs dict.iteritems. 

    Laurent> Both work, you may prefer xrange/iteritems for iteration on
    Laurent> large collections...

I find "iter<anything>" to be extremely ugly and hope to avoid using them
altogether until they are gone in Py3k.

Skip



More information about the Python-list mailing list