Tugger the SLUGger!SLUG Mailing List Archives

Re: [SLUG] C++ peer review.


On Tue, 2003-05-20 at 21:08, Greg Cockburn wrote:
> Hey,
> 
> if there are any C++ gurus (lifeless) out there who wouldn't mind taking a 
> quick look through my CS assignment and make a few comments.
> 
> It is an implementation of an ordered list given a skeleton to start with.
> 
> My (somewhat) completed version:
> http://www.performancemagic.com/~greg/OList.h
> Original skeleton:
> http://www.performancemagic.com/~greg/OList.h.orig  

If you were meant to do an implementation of it did the lecturer give
you a mainline test program that would exercise the code.  If he did not
then you would need to write one.  basic outline would be.

Create list,  use it including loop through the (non-existant)
members.   Is empty true?

Add one member to the list, is empty true?   loop through the list. 
remove the entry,  is empty empty.

create a two entry list,  is empty true?  loop through, verify you have
two entries.  Delete two entries, is empty empty?

Create a number of entries and destroy it.  Is all the space freed up. 
(How do you do this with free software?)

-- 
Thanks
KenF
OpenOffice.org developer