Say you have an array for which theithelement is the price of a given stock on dayi.If you were only permitted to complete at most one transaction (ie...
分类:
其他好文 时间:
2014-12-11 23:39:11
阅读次数:
212
Say you have an array for which theithelement is the price of a given stock on dayi.Design an algorithm to find the maximum profit. You may complete a...
分类:
其他好文 时间:
2014-12-11 00:16:55
阅读次数:
139
Problem Description
When the winter holiday comes, a lot of people will have a trip. Generally, there are a lot of souvenirs to sell, and sometimes the travelers will buy some ones with pleasure. N...
分类:
其他好文 时间:
2014-12-10 18:12:15
阅读次数:
167
Description
Lindsay is a shopaholic. Whenever there is a discount of the kind where you can buy three items and only pay for two, she goes completely mad and feels a need to buy all items in the st...
分类:
其他好文 时间:
2014-12-09 21:31:27
阅读次数:
166
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 transaction (ie, buy one and sell one share of the stock),...
分类:
其他好文 时间:
2014-12-09 17:56:20
阅读次数:
171