Golgappa.net | Golgappa.org | BagIndia.net | BodyIndia.Com | CabIndia.net | CarsBikes.net | CarsBikes.org | CashIndia.net | ConsumerIndia.net | CookingIndia.net | DataIndia.net | DealIndia.net | EmailIndia.net | FirstTablet.com | FirstTourist.com | ForsaleIndia.net | IndiaBody.Com | IndiaCab.net | IndiaCash.net | IndiaModel.net | KidForum.net | OfficeIndia.net | PaysIndia.com | RestaurantIndia.net | RestaurantsIndia.net | SaleForum.net | SellForum.net | SoldIndia.com | StarIndia.net | TomatoCab.com | TomatoCabs.com | TownIndia.com
Interested to Buy Any Domain ? << Click Here >> for more details...

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


Please Help Members By Posting Answers For Below Questions

How many bytes is a struct in c?

1153


code for quick sort?

2009


What is f'n in math?

1052


i have a written test for microland please give me test pattern

2722


What is new line escape sequence?

1319


I just typed in this program, and it is acting strangely. Can you see anything wrong with it?

992


What is a file descriptor in c?

1114


What header files do I need in order to define the standard library functions I use?

1042


Function calling procedures? and their differences? Why should one go for Call by Reference?

1075


Are there namespaces in c?

1106


Can you please compare array with pointer?

1065


Explain what math functions are available for integers? For floating point?

1098


What is exit() function?

1001


Is c easy to learn?

971


What is main () in c?

1054