working on tree.pl