> -----Original Message-----
> From: [EMAIL PROTECTED] [mailto:python-
> [EMAIL PROTECTED] On Behalf Of Tim Chase
> Sent: Wednesday, April 16, 2008 9:53 AM
> To: [EMAIL PROTECTED]
> Cc: python-list@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


-- 
http://mail.python.org/mailman/listinfo/python-list

Reply via email to