2015年8月22日
摘要: http://www.cnblogs.com/dingshilei/p/4125726.html 阅读全文
posted @ 2015-08-22 18:04 bendantuohai 阅读(135) 评论(0) 推荐(0) 编辑
摘要: 题目:给你一个股价序列,告诉你每个时间点的股价,问你什么时候买什么时候卖获利最大。时间复杂度越低越好。int max_difference(const vector& arr){ if (arr.size()>=2) { int MIN=min(arr[0],arr[1])... 阅读全文
posted @ 2015-08-22 17:30 bendantuohai 阅读(358) 评论(0) 推荐(0) 编辑