First page Back Continue Last page Overview Graphics

“Strange” Behaviour

>>> x = 3

>>> y = x

>>> y = 2

>>>

Variables in Python behave differently than those in C or C++

>>> x = 3

>>> x = 3

>>> y = x

x

y

3

2