how to find out the inorder successor of a node in a tree??
Answer Posted / atul kabra
Suppose we want to fint the inorder successor of N. Then
traverse one time right from N. And then traverse a left
subtree until u will get left pointer null node.
s=n->right;
while(s->left!=NULL)
s=s->left;
printf("\nInoder Successor is %d",s->info);
| Is This Answer Correct ? | 27 Yes | 42 No |
Post New Answer View All Answers
How many bytes is a struct in c?
code for quick sort?
What is f'n in math?
i have a written test for microland please give me test pattern
What is new line escape sequence?
I just typed in this program, and it is acting strangely. Can you see anything wrong with it?
What is a file descriptor in c?
What header files do I need in order to define the standard library functions I use?
Function calling procedures? and their differences? Why should one go for Call by Reference?
Are there namespaces in c?
Can you please compare array with pointer?
Explain what math functions are available for integers? For floating point?
What is exit() function?
Is c easy to learn?
What is main () in c?