1 research outputs found
A Simple Solution to the Level-Ancestor Problem
A Level Ancestory query LA(, ) asks for the the ancestor of the node
at a depth . We present a simple solution, which pre-processes the tree
in time with extra space, and answers the queries in $O(\log\
{n})$ time. Though other optimal algorithms exist, this is a simple enough
solution that could be taught and implemented easily