#两次遍历,循环迭代 # class TreeNode: # def __init__(self, x): # self.val = x # self.left = None # ...