Posted by hussein on July 14, 1999 at 23:38:48:
In Reply to: Re: list class posted by Gene on July 14, 1999 at 23:30:53:
: : : If we can't use the curr, head, and tail pointers, how are we supposed to use the methods already defined in the list class to implement our reverse method? Just about every method I want to use requires the use of a curr pointer!
: : also note that the question does not say u have to use the methods that have already been defined ... u should be creating a new method, which may be totally independent of the others ...
: Can we use temporary pointers?
yes, u can ... its just a regular function so u can do anything thats possible in a function ...
(although i should hint that its possible to write this code without any variable declarations, using only parameters and the Head pointer)
---
hussein