上一页 1 2 3 4 5 6 7 8 ··· 15 下一页
摘要: Given a non-empty string s and a dictionary wordDict containing a list of non-empty words, determine if s can be segmented into a space-separated sequ 阅读全文
posted @ 2017-09-29 14:39 Tsunami_lj 阅读(114) 评论(0) 推荐(0) 编辑
摘要: Given a binary tree, flatten it to a linked list in-place. For example,Given The flattened tree should look like: 阅读全文
posted @ 2017-09-28 11:05 Tsunami_lj 阅读(142) 评论(0) 推荐(0) 编辑
摘要: Given preorder and inorder traversal of a tree, construct the binary tree. Note:You may assume that duplicates do not exist in the tree. 解题思路:最经典的递归,已 阅读全文
posted @ 2017-09-28 00:08 Tsunami_lj 阅读(98) 评论(0) 推荐(0) 编辑
摘要: Given n, how many structurally unique BST's (binary search trees) that store values 1...n? For example,Given n = 3, there are a total of 5 unique BST' 阅读全文
posted @ 2017-09-27 17:28 Tsunami_lj 阅读(131) 评论(0) 推荐(0) 编辑
摘要: Given a set of distinct integers, nums, return all possible subsets. Note: The solution set must not contain duplicate subsets. For example,If nums =  阅读全文
posted @ 2017-09-27 16:25 Tsunami_lj 阅读(127) 评论(0) 推荐(0) 编辑
摘要: Given n pairs of parentheses, write a function to generate all combinations of well-formed parentheses. For example, given n = 3, a solution set is: 阅读全文
posted @ 2017-09-27 10:54 Tsunami_lj 阅读(139) 评论(0) 推荐(0) 编辑
摘要: Given a digit string, return all possible letter combinations that the number could represent. A mapping of digit to letters (just like on the telepho 阅读全文
posted @ 2017-09-27 10:24 Tsunami_lj 阅读(117) 评论(0) 推荐(0) 编辑
摘要: Given n non-negative integers a1, a2, ..., an, where each represents a point at coordinate (i, ai). n vertical lines are drawn such that the two endpo 阅读全文
posted @ 2017-09-26 20:19 Tsunami_lj 阅读(97) 评论(0) 推荐(0) 编辑
摘要: Implement regular expression matching with support for '.' and '*'. dp解法:膜 https://discuss.leetcode.com/topic/6183/my-concise-recursive-and-dp-solutio 阅读全文
posted @ 2017-09-26 13:24 Tsunami_lj 阅读(129) 评论(0) 推荐(0) 编辑
摘要: The string "PAYPALISHIRING" is written in a zigzag pattern on a given number of rows like this: (you may want to display this pattern in a fixed font 阅读全文
posted @ 2017-09-26 09:47 Tsunami_lj 阅读(104) 评论(0) 推荐(0) 编辑
上一页 1 2 3 4 5 6 7 8 ··· 15 下一页