[Tutor] scope question
Norvell Spearman
norvell@houseofspearman.org
Wed Jan 15 18:35:03 2003
On Wednesday, 2003.01.15, 15:42:27 -0700, Poor Yorick wrote:
> By the way, I finally got a good understanding of this by experimenting
> with passing mutable vs immutable objects into different test functions.
> You have to be careful when passing a mutable object like a list into a
> function because if you can change an element within the list the change
> will be visible to any variables referencing that list object, inside or
> outside of your function.
The tutorial I'm using is pretty good about stating each data type's
mutability or immutability; I probably need to go back and memorize
them. Thanks.
--
Norvell Spearman