Steven D'Aprano wrote: > Carl Banks wrote: > > > The shamelessness with which you inflated the verbosity of the latter > > is hilarious. > > [snip] > > > [ x**2 + y**2 for (x,y) in izip(xlist,ylist) ] > > > > Now there's no longer much advantage in conciseness for the map version > > (seeing that you'd have to define a function to pass to map), and this > > is more readable. > > and then, five minutes later in another post, wrote: > > > If you're doing heavy functional programming, > > listcomps are tremendously unwieldy compared to > > map et al. > > Having a dollar each way I see :-)
Don't think so. The verbosity I spoke of was your describing the code snippets in English, not the conciseness of the example. map and friends are more concise than listcomps, I wasn't arguing that, except that for the typical Pythonic use of listcomps it isn't much. One listcomp or one call to map is not "heavily functional." -- CARL BANKS -- http://mail.python.org/mailman/listinfo/python-list