Implemented only for one level depth of the tree.