摘要:
You are given coins of different denominations and a total amount of money amount. Write a function to compute the fewest number of coins that you nee... 阅读全文
posted @ 2015-12-31 14:07
neverlandly
阅读(366)
评论(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 complet... 阅读全文
posted @ 2015-12-31 13:15
neverlandly
阅读(870)
评论(0)
推荐(0)
摘要:
Given two sparse matrices A and B, return the result of AB.You may assume that A's column number is equal to B's row number.Example:A = [ [ 1, 0, 0],... 阅读全文
posted @ 2015-12-31 07:57
neverlandly
阅读(2555)
评论(0)
推荐(0)
摘要:
参考http://segmentfault.com/a/1190000003797204 and http://blog.csdn.net/u013027996/article/details/48713751 深度优先搜索 复杂度 时间 O(N^2) 空间 O(N) 思路 因为要输出所有可能的情况 阅读全文
posted @ 2015-12-31 07:13
neverlandly
阅读(331)
评论(0)
推荐(0)
摘要:
Remove the minimum number of invalid parentheses in order to make the input string valid. Return all possible results. Note: The input string may cont 阅读全文
posted @ 2015-12-31 02:34
neverlandly
阅读(1484)
评论(0)
推荐(0)
浙公网安备 33010602011771号