摘要: ```C++ class Solution { public: vector findDisappearedNumbers(vector& nums) { vector res; int m; for(int i=0;i 0){ nums[m] *= -1; } } ... 阅读全文
posted @ 2018-08-08 16:52 一条图图犬 阅读(263) 评论(0) 推荐(0) 编辑
摘要: ```python3 class Solution: def containsDuplicate(self, nums): """ :type nums: List[int] :rtype: bool """ s = set() for i in nums: if i i... 阅读全文
posted @ 2018-08-08 16:25 一条图图犬 阅读(184) 评论(0) 推荐(0) 编辑
摘要: class Solution { public: int maxProfit(vector& prices) { if( prices.empty() || prices.size() prices[i] mi ? res:prices[i] mi; mi = mi 阅读全文
posted @ 2018-08-08 16:20 一条图图犬 阅读(169) 评论(0) 推荐(0) 编辑