Welcome back. Sometimes, you'll want to change an object after you've created it.
You create a list,
I'm going to keep adding items onto the end of the list.
Create a turtle, change it's pen color.
There are two ways to change the value of an object after you've created it.
One, you can make a modified copy of the object.
And the other is to modify the original.
We'll call that mutation,
and it's useful but sometimes confusing.
So today's lesson; How mutation of existing objects works,
recognizing the potential confusion that that can cause.
At the end of today's lesson,
you should be able to identify whether an object is mutable or immutable.
You should be able to identify whether a method mutates
an object or creates a modified copy of it.
And you should be able to recognize when
two different variables are aliases for the same object,
and predict whether an operation on one of those variables is going
to cause an impact on the contents of the other one.