摘要: Given a binary search tree and the lowest and highest boundaries as L and R, trim the tree so that all its elements lies in [L, R] (R >= L). You might 阅读全文
posted @ 2018-01-09 21:34 抒抒说 阅读(98) 评论(0) 推荐(0) 编辑
摘要: Given a list of strings words representing an English Dictionary, find the longest word in words that can be built one character at a time by other wo 阅读全文
posted @ 2018-01-09 21:31 抒抒说 阅读(120) 评论(0) 推荐(0) 编辑
摘要: The set S originally contains numbers from 1 to n. But unfortunately, due to the data error, one of the numbers in the set got duplicated to another n 阅读全文
posted @ 2018-01-09 03:46 抒抒说 阅读(149) 评论(0) 推荐(0) 编辑
摘要: Given a non-empty string s, you may delete at most one character. Judge whether you can make it a palindrome. Example 1: Input: "aba" Output: True Exa 阅读全文
posted @ 2018-01-09 03:41 抒抒说 阅读(166) 评论(0) 推荐(0) 编辑
摘要: Initially on a notepad only one character 'A' is present. You can perform two operations on this notepad for each step: Copy All: You can copy all the 阅读全文
posted @ 2018-01-09 03:35 抒抒说 阅读(162) 评论(0) 推荐(0) 编辑
摘要: Given an array of integers nums, write a method that returns the "pivot" index of this array. We define the pivot index as the index where the sum of 阅读全文
posted @ 2018-01-09 03:29 抒抒说 阅读(165) 评论(0) 推荐(0) 编辑