non-recursive inorder,preorder,postorder tree traversal