
上QQ阅读APP看书,第一时间看更新
Argument passing semantics – pass by object-reference
Now let's look at how all this relates to function arguments and return values. When we call a function, we literally create new name bindings — those declared in the function definition — to existing objects — those passed in at the call itself. As such, it's important to really understand Python reference semantics if you want to know how your functions work.