finding the target node present in path of tree

Revision en1, by pal_saab, 2021-11-26 07:51:08

we have given rooted tree , and target node and some other node A, we have to check if target node present in simple path from root to A , please tell me how to check this in o(1)

History

 
 
 
 
Revisions
 
 
  Rev. Lang. By When Δ Comment
en1 English pal_saab 2021-11-26 07:51:08 232 Initial revision (published)