tree structure maintained