Thread: pointer help
View Single Post
Old Mar 31st, 2006, 2:48 PM   #29
nnxion
Programming Guru
 
nnxion's Avatar
 
Join Date: Jun 2005
Location: elemental plane
Posts: 1,429
Rep Power: 5 nnxion is on a distinguished road
You haven't changed anything to what The Dark said, it calls recursively. Why are you? What is supposed to happen to the insert? When is it supposed to swap the values or which value goes left and which goes right? Why are you checking to see if the nodes are NULL when they always are? Think about how it should go, work it out on paper if you have to. I'll try to work it out tomorrow, got to go to sleep now. Good luck!

EDIT: Maybe this will help you understand.
__________________
"Employ your time in improving yourself by other men's writings, so that you shall gain easily what others have labored hard for."
-- Socrates
nnxion is offline   Reply With Quote