上一页 1 2 3 4 5 6 7 8 ··· 17 下一页
摘要: link class Solution { public: stack<string> stk; unordered_map<string,multiset<string>> mp; vector<string> findItinerary(vector<vector<string>>& ticke 阅读全文
posted @ 2020-06-29 17:00 feibilun 阅读(90) 评论(0) 推荐(0) 编辑
摘要: link class Solution { public: int findMaxValueOfEquation(vector<vector<int>>& points, int k) { deque<int> dq; int n=points.size(); int res=INT_MIN; fo 阅读全文
posted @ 2020-06-28 17:15 feibilun 阅读(172) 评论(0) 推荐(0) 编辑
摘要: link class Solution { public: bool canArrange(vector<int>& arr, int k) { unordered_map<int,int> cnt; for(int i:arr){ cnt[(i%k+k)%k]++; } if(cnt[0]&1) 阅读全文
posted @ 2020-06-28 17:07 feibilun 阅读(79) 评论(0) 推荐(0) 编辑
摘要: link class Solution { public: int findDuplicate(vector<int>& nums) { int slow=0; int fast=0; while(true){ slow=nums[slow]; fast=nums[nums[fast]]; if(s 阅读全文
posted @ 2020-06-28 09:45 feibilun 阅读(98) 评论(0) 推荐(0) 编辑
摘要: link referenct to @617280219 Sort and group edges by weight. In each step we process one group of edges Discard the edges whose ends are already conne 阅读全文
posted @ 2020-06-28 08:39 feibilun 阅读(163) 评论(0) 推荐(0) 编辑
摘要: link 每一位1的个数有三种状态,0,1,2,3(0) 用两个bit,low和high来记录这些状态。 class Solution { public: int singleNumber(vector<int>& nums) { int high=0; int low=0; for(int n:n 阅读全文
posted @ 2020-06-23 09:53 feibilun 阅读(68) 评论(0) 推荐(0) 编辑
摘要: link #include <iostream> #include <vector> #include <algorithm> #include <unordered_set> #include <cstring> #include <queue> #include <stack> # define 阅读全文
posted @ 2020-06-20 17:42 feibilun 阅读(87) 评论(0) 推荐(0) 编辑
摘要: link class Solution { public: const int mod=1E9+7; vector<long long> powerof26; string longestDupSubstring(string S) { int n=S.size(); powerof26.resiz 阅读全文
posted @ 2020-06-20 09:29 feibilun 阅读(120) 评论(0) 推荐(0) 编辑
摘要: 环境搭建 https://fishc.com.cn/forum.php?mod=viewthread&tid=156177&highlight=MASM 在dosbox运行,首先需要mount c 文件所在文件夹 源程序文件夹中需要 LINK.EXE, MASM.EXE, ML.EXE, DOSXN 阅读全文
posted @ 2020-06-12 23:04 feibilun 阅读(593) 评论(0) 推荐(0) 编辑
摘要: Link class Solution { public: void sortColors(vector<int>& nums) { int low=0; int high=nums.size()-1; for(int i=0;i<=high;){ if(nums[i]==0){ swap(nums 阅读全文
posted @ 2020-06-12 07:51 feibilun 阅读(53) 评论(0) 推荐(0) 编辑
上一页 1 2 3 4 5 6 7 8 ··· 17 下一页