@pansiano Tu masz fajnie opisane jak to działa - https://realpython.com/python-pass-by-reference/
Generalnie gorąco polecam Real Pythona, dużo ciekawych artykułów tam jest.
Co do samego zachowania argumentów funkcji to w JSie jest to tak samo zrobione zdaje się, także to nie czysto Pytonowe zjawisko
Pass by Reference in Python: Background and Best Practices – Real PythonIn this tutorial, you'll explore the concept of passing by reference and learn how it relates to Python's own system for handling function arguments. You'll look at several use cases for passing by reference and learn some best practices for implementing pass-by-reference constructs in Python.Realpython