PostOrder Transversal binary search tree?
suppose this is the binary search tree
code for post order transversal
It will print 8 then 3 then 1
void preorder(struct tree *rt)
after printing 1 this statement will execute
preorder(rt->lchild); because the left of node which contains 1 is NULL so in this recursive function preorder(rt->lchild); null will be passed. then root will also become NULL thats why this if statement will execute
Now what will happen after returning in which statement control will be passed ?