add avl tree, a little complex