摘要: class Solution { public: int maxProfit(vector& prices) { int local=0,golal = 0; for (int i=0; i<prices.size()-1; i++) { local = ma... 阅读全文
posted @ 2017-10-11 23:58 799 阅读(113) 评论(0) 推荐(0) 编辑
摘要: 题意:给定序列,找出max(prices[j] - prices[i]) ( j > i) 动态规划 : local = max ( local + prices[i+1] - prices[i], 0); 阅读全文
posted @ 2017-10-11 16:17 799 阅读(114) 评论(0) 推荐(0) 编辑
摘要: 题意:两个有序vector 合并保持有序 阅读全文
posted @ 2017-10-11 15:34 799 阅读(105) 评论(0) 推荐(0) 编辑
摘要: 小记:没有信仰的人,犹如惊弓之鸟。 阅读全文
posted @ 2017-10-11 14:32 799 阅读(139) 评论(0) 推荐(0) 编辑