LeetCode - Kth Smallest Element in a BST
摘要:
那么这道题给的提示是让我们用BST的性质来解题,最重要的性质是就是左<根<右,那么如果用中序遍历所有的节点就会得到一个有序数组。所以解题的关键还是中序遍历啊。 阅读全文
posted @ 2018-05-21 12:10 IncredibleThings 阅读(88) 评论(0) 推荐(0) 编辑
2018年5月21日 #
posted @ 2018-05-21 12:10 IncredibleThings 阅读(88) 评论(0) 推荐(0) 编辑
posted @ 2018-05-21 10:42 IncredibleThings 阅读(105) 评论(0) 推荐(0) 编辑
posted @ 2018-05-21 03:45 IncredibleThings 阅读(103) 评论(0) 推荐(0) 编辑
posted @ 2018-05-21 01:16 IncredibleThings 阅读(112) 评论(0) 推荐(0) 编辑