I have tried the following in the console:
>>> def f(l=[]):
... l.append(1)
... print(l)
... del l
...
>>> f()
[1]
>>> f()
[1, 1]
What I don't understand is how the interpreter is still able to find the same list l after the delete instruction.
From the documentation l=[] should be evaluated only once.
lis created and set to the value of the default argument. The default argument's value is created on function definition, but the variablelis created each time the function runs.delof a local variable, right at the end of a function, is NEVER going to have any effect whatsoever. It's exactly what's going to happen to the variable anyway.