Originally Posted by
andrewh
I think I see what you mean. The pointer has advanced to node 3 at the
end of the program and if I want to access the node 2, I have to do reverse
direction to the pointer to get the data in 2nd node.
Here how they:
1st node: root->next
root->x
2nd node: conductor->next
conductor->x
3rd node: conductor->next
conductor->x
As you noticed at the end of the program, I was able to read the data of the 1st node. I guess this because the pointer was unique. If we have to name every pointer a unique name then, that would not be practical. I would to be able to
read the 2nd node when I have traversed to the end of the above link list.
I guess the question is: How do I travel in reverse on pointers?
Thanks again,
Andrew