How do I push a Node from a linked list onto the stack - do we just have to push the data element, or the node - I think I confused myself a bit. Any light that can be shed on this matter will be of great help thanks. An Example will be great.
IP/Host: ---.cache.isnet.net
Registered: 18 years ago
Posts: 133
Rating: 0
Just the data element.
The node in its entirety is designed to keep track of its position in the list. You wont need the linked lists's position info in a stack so just keep the data element.