Python complaints
Mike Fletcher
mfletch at tpresence.com
Tue Dec 14 10:13:55 EST 1999
for first, second, third in [
(a/x, a**2, y)
for a in listone,
for y in [(l3val**4) for l3val in listthree],
for x in [(2**math.PI**l4val) for l4val in listfour],
]:
print first, second, third
Or something similar is probably what people are hyped about. I.e. complex
parallel processing of multiple lists with multiple levels of comprehension
(ww?). Note, I'm sure someone will want to add "for i indexing x in []"
syntax to this construct :) .
Cheers,
Mike
-----Original Message-----
From: Charles Boncelet [mailto:boncelet at udel.edu]
Sent: Tuesday, December 14, 1999 6:13 AM
To: python-list at python.org
Subject: Re: Python complaints
...
This is the first I've seen of this notation and it is simple and
(reasonably)
understandable. But the savings is minimal versus normal Python
fx = []
for a in x:
fx.append(a**2)
Am I missing something?
...
More information about the Python-list
mailing list