First I'm going to start like everyone else. I'm new to python. My teacher gave me the problem:
def f(a, b, c):
a = 1
c = b
c[0] = 2
a = 10
b = [11, 12, 13]
c = [13, 14, 15]
f(a, b, c)
print a, b, c
It prints:
10 [2, 12, 13] [13, 14, 15]
I understand that a stays at 10 because integers are immutable, but I don't understand why b changes and c doesn't.