摘要: link 解法: maxprime存一个数的最大质因数,primeMin[i] 一个数n的质因数存在i,以n结尾所分得的最小子数组数。 class Solution { public: static const int maxn=1000000; int maxprime[maxn+1]; int 阅读全文
posted @ 2020-04-28 18:28 feibilun 阅读(264) 评论(0) 推荐(0)
摘要: class Solution { public: vector<int> singleNumbers(vector<int>& nums) { int total=0; for(int i:nums) total^=i; int one=1; while((one&total)==0) one<<= 阅读全文
posted @ 2020-04-28 10:01 feibilun 阅读(123) 评论(0) 推荐(0)