結果 : how to traverse a tree in python