So Python is pass by reference. Always. But objects like integers, strings, and tuples, even when passed into a function, cannot be changed (hence they are called immutable). Here is an example.
def foo(i, l):
i = 5 # this creates a new variable which is also called i
l = [1, 2] # this changes the existing variable called l
i = 10
l = [1, 2, 3]
print(i)
# i = 10
print(l)
# l = [1, 2, 3]
foo(i, l)
print(i)
# i = 10 # variable i defined outside of function foo didn't change
print(l)
# l = [1, 2] # l is defined outside of function foo did change
So you can see that the integer object is immutable while the list object is mutable.
What's the reason for even having immutable objects in Python? What advantages and disadvantages would there be for a language like Python if all the objects were mutable?