how can I avoid abusing lists?

Simon Forman rogue_pedro at yahoo.com
Fri Jul 7 14:36:00 EDT 2006


Tim Chase wrote:

>
> You'll notice that the OP's code had multiple references to the
> same counter (0, 1, and 3 all mapped to type1)
>
> The OP's method was about as good as it gets.  One might try to

D'oh!  Didn't notice that.

Yeah, Thomas,  if you really do want more than "type code" (i.e. key to
your map dict) to map to the same type counter then IMHO your original
method is very apt.

Peace,
~Simon




More information about the Python-list mailing list