A really bad idea.

Daniel Dittmar daniel.dittmar at sap.com
Fri Nov 15 11:43:21 EST 2002


holger krekel wrote:
> But in fact i'd like to see some examples of what is readable and
> what is not readable in your oppinion.

zip, enumerate: readable, because you can search the docs for the words. It
is also easy to implement variations: returning other datatypes, returning
an iterator to preserve memory. Thus the whole program becomes easier to
understand because similar task are called in a similar way.

list comprehension: not readable, because you don't know what to search for.
You can't create dictionary comprehension or generator comprehension (both
have been proposed on c.l.p), thus making the resulting program less
regular.

Daniel






More information about the Python-list mailing list