Şansal Birbaş wrote:
> for i in range(1,5):
> for j in i*range(max_expander+1):
> for k in i*range(max_expander+1):
> for m in i*range(max_expander+1):
> for r in i*range(max_expander+1):
I must be missing something, but I can't see why
Şansal Birbaş, 23.02.2011 07:34:
I needed to find the cheapest combination among given data and I developed an
algorithm for this task. It works correctly. But it takes much time (nearly 2
minutes) for second function to find the result while it is just
one second for the first function. How ca
Nothing changed, Mr. Chris
-Original Message-
From: ch...@rebertia.com [mailto:ch...@rebertia.com] On Behalf Of Chris Rebert
Sent: Wednesday, February 23, 2011 9:37 AM
To: Şansal Birbaş
Cc: python-list@python.org
Subject: Re: Accelerating For Loop
2011/2/22 Şansal Birbaş :
> Hi
2011/2/22 Şansal Birbaş :
> Hi All,
>
> I needed to find the cheapest combination among given data and I developed
> an algorithm for this task. It works correctly. But it takes much time
> (nearly 2 minutes) for second function to find the result while it is just
> one second for the first functio
Hi All,
I needed to find the cheapest combination among given data and I developed an
algorithm for this task. It works correctly. But it takes much time (nearly 2
minutes) for second function to find the result while it is just
one second for the first function. How can I improve the calculatio