上一页 1 2 3 4 5 6 7 8 ··· 26 下一页
摘要: Find thekth largest element in an unsorted array. Note that it is the kth largest element in the sorted order, not the kth distinct element.For exampl... 阅读全文
posted @ 2015-08-06 21:04 ~每天进步一点点~ 阅读(123) 评论(0) 推荐(0) 编辑
摘要: Given a string S, you are allowed to convert it to a palindrome by adding characters in front of it. Find and return the shortest palindrome you can f... 阅读全文
posted @ 2015-08-06 20:58 ~每天进步一点点~ 阅读(120) 评论(0) 推荐(0) 编辑
摘要: Note:This is an extension ofHouse Robber.After robbing those houses on that street, the thief has found himself a new place for his thievery so that h... 阅读全文
posted @ 2015-08-06 19:58 ~每天进步一点点~ 阅读(126) 评论(0) 推荐(0) 编辑
摘要: Given a 2D board and a list of words from the dictionary, find all words in the board.Each word must be constructed from letters of sequentially adjac... 阅读全文
posted @ 2015-08-06 10:42 ~每天进步一点点~ 阅读(105) 评论(0) 推荐(0) 编辑
摘要: Design a data structure that supports the following two operations:void addWord(word)bool search(word)search(word) can search a literal word or a regu... 阅读全文
posted @ 2015-08-05 22:24 ~每天进步一点点~ 阅读(241) 评论(0) 推荐(0) 编辑
摘要: There are a total ofncourses you have to take, labeled from0ton - 1.Some courses may have prerequisites, for example to take course 0 you have to firs... 阅读全文
posted @ 2015-08-05 21:47 ~每天进步一点点~ 阅读(187) 评论(0) 推荐(0) 编辑
摘要: Given an array ofnpositive integers and a positive integers, find the minimal length of a subarray of which the sum ≥s. If there isn't one, return 0 i... 阅读全文
posted @ 2015-08-04 22:36 ~每天进步一点点~ 阅读(102) 评论(0) 推荐(0) 编辑
摘要: Trie树又被称为字典树、前缀树,是一种用于快速检索的多叉树。Tried树可以利用字符串的公共前缀来节省存储空间。但如果系统存在大量没有公共前缀的字符串,相应的Trie树将非常消耗内存。(下图为Wiki上的Trie树示意图, https://en.wikipedia.org/wiki/Trie)子节... 阅读全文
posted @ 2015-08-04 22:27 ~每天进步一点点~ 阅读(137) 评论(0) 推荐(0) 编辑
摘要: There are a total ofncourses you have to take, labeled from0ton - 1.Some courses may have prerequisites, for example to take course 0 you have to firs... 阅读全文
posted @ 2015-08-04 21:54 ~每天进步一点点~ 阅读(125) 评论(0) 推荐(0) 编辑
摘要: Reverse a singly linked list./** * Definition for singly-linked list. * public class ListNode { * int val; * ListNode next; * ListNode(int... 阅读全文
posted @ 2015-08-03 22:38 ~每天进步一点点~ 阅读(142) 评论(0) 推荐(0) 编辑
上一页 1 2 3 4 5 6 7 8 ··· 26 下一页