David Duerrenmatt wrote:
> For some reasons, I've to use Python 1.5.2 and am looking for a workaround:
>
> In newer Python versions, I can call a function this way:
>
> func = some_function
> func(*params)
>
> Then, the list/tuple named params will automatically be "expanded" and
> n=len(params) a
Great, this is exactly what I was looking for.
Thanks all of you for your immediate answer!
Nick Smallbone schrieb:
> David Duerrenmatt wrote:
>
>>Hi there
>>
>>For some reasons, I've to use Python 1.5.2 and am looking for a workaround:
>>
>>In newer Python versions, I can call a function thi
David Duerrenmatt wrote:
> Hi there
>
> For some reasons, I've to use Python 1.5.2 and am looking for a workaround:
>
> In newer Python versions, I can call a function this way:
>
> func = some_function
> func(*params)
>
I think the "apply" function is what you want:
apply(object[, args[, kwargs]
David Duerrenmatt wrote:
> For some reasons, I've to use Python 1.5.2 and am looking for a
> workaround:
>
> In newer Python versions, I can call a function this way:
>
> func = some_function
> func(*params)
Use
apply(func, params)
Peter
--
http://mail.python.org/mailman/listinfo/python-l