Current Forum: 15-211 Main Forum |
Date: Mon Sep 24 2001 1:51 pm |
Author: Lee, Peter <petel@cmu.edu> |
Subject: Re: the implementation of Append() in (abstract)Class List |
|
|
Well, perhaps Bill and I will try to spend some lecture time on why this is such a useful way to implement Append. It would be very hard to do that in this forum.
The shortest answer I can give now is to simply point out that, with this definition of Append, both of the original lists are still preserved, and with the minimal amount of copying. The usefulness of preserving old versions of data structures comes up in many different applications, some of which we'll encounter in the bigger projects this term.
More in lectures... |
|