摘要: Python解法代码: class Solution: def intersect(self, nums1: List[int], nums2: List[int]) -> List[int]: nums1.sort() nums2.sort() r = [] i = j = 0 while i < 阅读全文
posted @ 2019-12-24 14:26 HannahGreen 阅读(465) 评论(0) 推荐(0) 编辑
摘要: C++解题方法: class Solution { public: vector<int> intersection(vector<int>& nums1, vector<int>& nums2) { unordered_set<int> u; vector<int> answer; for(int 阅读全文
posted @ 2019-12-24 10:54 HannahGreen 阅读(153) 评论(0) 推荐(0) 编辑
摘要: C++解题代码: class Solutiion { public: bool isAnagram(string s, string t) { int *data = new int[26](); int n = s.length(); int m = t.length(); int temp; i 阅读全文
posted @ 2019-12-24 09:49 HannahGreen 阅读(254) 评论(0) 推荐(0) 编辑