上一页 1 ··· 8 9 10 11 12 13 14 15 16 ··· 27 下一页
摘要: Given a string s and a dictionary of words dict, determine if s can be segmented into a space-separated sequence of one or more dictionary words. For 阅读全文
posted @ 2016-12-13 20:49 wxquare 阅读(209) 评论(0) 推荐(0) 编辑
摘要: Trie 树的一个应用 Design a data structure that supports the following two operations: search(word) can search a literal word or a regular expression string 阅读全文
posted @ 2016-12-13 20:44 wxquare 阅读(404) 评论(0) 推荐(0) 编辑
摘要: Trie 树实现 Implement a trie with insert, search, and startsWith methods. 参看:http://www.cnblogs.com/grandyang/p/4491665.html 阅读全文
posted @ 2016-12-13 20:42 wxquare 阅读(172) 评论(0) 推荐(0) 编辑
摘要: The set [1,2,3,…,n] contains a total of n! unique permutations. By listing and labeling all of the permutations in order,We get the following sequence 阅读全文
posted @ 2016-12-09 16:05 wxquare 阅读(137) 评论(0) 推荐(0) 编辑
摘要: Given a list of airline tickets represented by pairs of departure and arrival airports [from, to], reconstruct the itinerary in order. All of the tick 阅读全文
posted @ 2016-11-27 11:02 wxquare 阅读(163) 评论(0) 推荐(0) 编辑
摘要: There are a total of n courses you have to take, labeled from 0 to n - 1. Some courses may have prerequisites, for example to take course 0 you have t 阅读全文
posted @ 2016-11-26 22:21 wxquare 阅读(228) 评论(0) 推荐(0) 编辑
摘要: There are a total of n courses you have to take, labeled from 0 to n - 1. Some courses may have prerequisites, for example to take course 0 you have t 阅读全文
posted @ 2016-11-26 22:18 wxquare 阅读(251) 评论(0) 推荐(0) 编辑
摘要: 在已经排好序的区间中,插入一个新的区间,与merge的做法类似 在已经排好序的区间中,插入一个新的区间,与merge的做法类似 Given a set of non-overlapping intervals, insert a new interval into the intervals (me 阅读全文
posted @ 2016-11-11 14:51 wxquare 阅读(159) 评论(0) 推荐(0) 编辑
摘要: Given a collection of intervals, merge all overlapping intervals. For example,Given [1,3],[2,6],[8,10],[15,18],return [1,6],[8,10],[15,18]. 区间合并,分为三种情 阅读全文
posted @ 2016-11-11 14:44 wxquare 阅读(176) 评论(0) 推荐(0) 编辑
摘要: Given a list of non negative integers, arrange them such that they form the largest number. For example, given [3, 30, 34, 5, 9], the largest formed n 阅读全文
posted @ 2016-11-11 10:52 wxquare 阅读(186) 评论(0) 推荐(0) 编辑
上一页 1 ··· 8 9 10 11 12 13 14 15 16 ··· 27 下一页