working with pointers

Dave Brueck dave at pythonapocrypha.com
Tue May 31 15:01:12 EDT 2005


Michael wrote:
> sorry, I'm used to working in c++ :-p
> 
> if i do
> a=2
> b=a
> b=0
> then a is still 2!?
> 
> so when do = mean a reference to the same object 

Always.

> and when does it mean make a copy of the object??

Never.

-Dave



More information about the Python-list mailing list