On 8/18/11 2:35 AM, Stan Schymanski wrote:
Dear Robert,

Thanks a lot for your help, this is exactly what I wanted. I still
don't get why it is necessary to import a special function to perform
such a standard thing. "import copy" has the affect that suddenly I
cannot do copy(L) any more, but I have to do copy.copy(L) instead.
Since copy(L) does not do what I would expect anyway, I will avoid it.
Frankly, as intuitive as Python is in other respects, this behaviour
blows my mind.

In a file, you could do

from copy import deepcopy

and then you would just have the deepcopy function, without overwriting your copy function.

As Simon points out, this is already done by default in Sage, though.

Thanks,

Jason

--
To post to this group, send email to sage-support@googlegroups.com
To unsubscribe from this group, send email to 
sage-support+unsubscr...@googlegroups.com
For more options, visit this group at 
http://groups.google.com/group/sage-support
URL: http://www.sagemath.org

Reply via email to