update binary tree preorder travsal