摘要:
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... 阅读全文
摘要:
Implement a trie withinsert,search, andstartsWithmethods.Note:You may assume that all inputs are consist of lowercase lettersa-z.思路: 构建一个简单的字典树,要求实现... 阅读全文
摘要:
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 he wil... 阅读全文
摘要:
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... 阅读全文
摘要:
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... 阅读全文