二叉搜索树的前序遍历由 12, 8, 6, 2, 7, 9, 10, 16, 15, 19, 17, 20 给出。
那么这棵树的后序遍历是:
(一) 2, 6, 7, 8, 9, 10, 12, 15, 16, 17, 19, 20
(乙) 2, 7, 6, 10, 9, 8, 15, 17, 20, 19, 16, 12
(C) 7, 2, 6, 8, 9, 10, 20, 17, 19, 15, 16, 12
(四) 7, 6, 2, 10, 9, 8, 15, 16, 17, 20, 19, 12答案:(乙)
解释:从前序画二叉搜索树,然后写后序。
这个问题的测验