摘要:
题目:There are N children standing in a line. Each child is assigned a rating value. You are giving candies to these children subjected to the followin... 阅读全文
posted @ 2014-07-30 08:50
爱做饭的小莹子
阅读(1826)
评论(0)
推荐(0)
摘要:
题目:Given n non-negative integers representing an elevation map where the width of each bar is 1, compute how much water it is able to trap after rain... 阅读全文
posted @ 2014-07-30 08:21
爱做饭的小莹子
阅读(3864)
评论(0)
推荐(0)
摘要:
题目:Say you have an array for which the ith element is the price of a given stock on day i.Design an algorithm to find the maximum profit. You may com... 阅读全文
posted @ 2014-07-30 05:23
爱做饭的小莹子
阅读(3161)
评论(0)
推荐(0)
摘要:
题目:Say you have an array for which the ith element is the price of a given stock on day i.Design an algorithm to find the maximum profit. You may com... 阅读全文
posted @ 2014-07-30 04:58
爱做饭的小莹子
阅读(2830)
评论(0)
推荐(0)
摘要:
题目:Say you have an array for which the ith element is the price of a given stock on day i.If you were only permitted to complete at most one transact... 阅读全文
posted @ 2014-07-30 04:24
爱做饭的小莹子
阅读(1798)
评论(0)
推荐(0)
摘要:
题目: Find the contiguous subarray within an array (containing at least one number) which has the largest sum.For example, given the array [−2,1,−3,4,−1... 阅读全文
posted @ 2014-07-30 04:06
爱做饭的小莹子
阅读(6342)
评论(0)
推荐(0)
摘要:
题目:Given a string s and a dictionary of words dict, add spaces in s to construct a sentence where each word is a valid dictionary word.Return all suc... 阅读全文
posted @ 2014-07-30 02:49
爱做饭的小莹子
阅读(3394)
评论(0)
推荐(0)