Le 28/04/2020 à 09:13, Chris Angelico a écrit :
On Tue, Apr 28, 2020 at 4:56 PM ast <ast@invalid> wrote:

Le 27/04/2020 à 04:46, Bob van der Poel a écrit :



"Best"? Not sure about that. Functions are first-class objects in
Python, so a function *is* a callable object. You don't have to create
a custom class with a call method just to be able to attach attributes
to your function.

ChrisA


Using a mutable object as a function default parameter value
and changing it inside the function looks like a "trick"
according to me.
--
https://mail.python.org/mailman/listinfo/python-list

Reply via email to