Re: [algogeeks] Re: deep vs shallow copy

2011-11-18 Thread atul anand
http://www.learncpp.com/cpp-tutorial/912-shallow-vs-deep-copying/ On Fri, Nov 18, 2011 at 8:30 PM, Dheeraj Jain wrote: > http://geeksforgeeks.org/forum/topic/deep-copy-vs-shallow-copy > > > On Fri, Nov 18, 2011 at 12:58 PM, Gene wrote: > >> The most extreme shallow copy is just copying a pointe

Re: [algogeeks] Re: deep vs shallow copy

2011-11-18 Thread Dheeraj Jain
http://geeksforgeeks.org/forum/topic/deep-copy-vs-shallow-copy On Fri, Nov 18, 2011 at 12:58 PM, Gene wrote: > The most extreme shallow copy is just copying a pointer to a large > data structure like a graph or tree. Deep copy is copying the entire > data structure and returning a new pointer.

[algogeeks] Re: deep vs shallow copy

2011-11-17 Thread Gene
The most extreme shallow copy is just copying a pointer to a large data structure like a graph or tree. Deep copy is copying the entire data structure and returning a new pointer. Here is a more common example: typedef struct list { struct list *next; void *data; } LIST_NODE; In practice yo