script question

Peter Pearson ppearson at nowhere.invalid
Fri Apr 17 17:07:18 CEST 2009


On 17 Apr 2009 07:03:18 -0700, Aahz <aahz at pythoncraft.com> wrote:
> In article <m263h3vadt.fsf at cs.uu.nl>, Piet van Oostrum wrote:
>>
>>funclist = [func01, func02, func03, ... ]
>>for i in range(1,n):
>>    funclist[i]()
>
> Go to all that trouble, you might as well make it easier:
>
> for func in funclist:
>     func()

Yes.  Especially because func01 gets called, this way.

-- 
To email me, substitute nowhere->spamcop, invalid->net.



More information about the Python-list mailing list