I have resigned using pointers as internal structure of Tree