1 Antwort
+ 2
An object is mutable if and only if there is at least one elementary operation over that object that *changes* the object.
For instance the methods append, sort and reverse on the lists. These change the list without recreating the list (and they return None)
However, the string methods (lower, upper, strip...) recreate the modified string and return it.