vary number of loops

Reedick, Andrew jr9445 at ATT.COM
Wed Apr 16 16:12:26 CEST 2008


> -----Original Message-----
> From: python-list-bounces+jr9445=att.com at python.org [mailto:python-
> list-bounces+jr9445=att.com at python.org] On Behalf Of Tim Chase
> Sent: Wednesday, April 16, 2008 9:53 AM
> To: nullgraph at gmail.com
> Cc: python-list at python.org
> Subject: Re: vary number of loops
> 
> >
> > If n=3, I want to have 3 sets of elements and mix them up using 3
for
> > loops.
> 
> You might be ineterested in this thread:
> 
> http://mail.python.org/pipermail/python-list/2008-January/473650.html
> 
> where various solutions were proposed and their various merits
> evaluated.
> 

I second that.  The thread compared building loops on the fly, building
comprehensions nested to arbitrarily levels, recursion (sloooow!), a
slick cookbook recipe using iterators, etc. and provided timings for
each method.  Definitely worth bookmarking.



*****

The information transmitted is intended only for the person or entity to which it is addressed and may contain confidential, proprietary, and/or privileged material. Any review, retransmission, dissemination or other use of, or taking of any action in reliance upon this information by persons or entities other than the intended recipient is prohibited. If you received this in error, please contact the sender and delete the material from all computers. GA625





More information about the Python-list mailing list