个人博客:https://luxialan.com

摘要: Givenn, how many structurally uniqueBST's(binary search trees) that store values 1...n?For example,Givenn= 3, there are a total of 5 unique BST's. 1... 阅读全文
posted @ 2014-12-07 11:30 luxialan 阅读(127) 评论(0) 推荐(0) 编辑
摘要: Convert Sorted Array to Binary Search TreeGiven an array where elements are sorted in ascending order, convert it to a height balanced BST.这道题本质上是二分搜索... 阅读全文
posted @ 2014-12-07 10:49 luxialan 阅读(117) 评论(0) 推荐(0) 编辑