摘要:
https://leetcode.com/problems/base-7/#/description 阅读全文
摘要:
public class Solution { public bool IsAnagram(string s, string t) { Dictionary<char, int> dic = new Dictionary<char, int>(); foreach (var c in s) { if 阅读全文
摘要:
public class Solution { public int MajorityElement(int[] nums) { Dictionary<int, int> dic = new Dictionary<int, int>(); var len = nums.Length; for (in 阅读全文
摘要:
/** * Definition for a binary tree node. * public class TreeNode { * public int val; * public TreeNode left; * public TreeNode right; * public TreeNod 阅读全文
摘要:
/** * Definition for singly-linked list. * public class ListNode { * public int val; * public ListNode next; * public ListNode(int x) { val = x; } * } 阅读全文
摘要:
https://leetcode.com/problems/excel-sheet-column-number/#/description 补充一个python的实现: 阅读全文
摘要:
public class Solution { public int MaxProfit(int[] prices) { var list = new List<KeyValuePair<int, int>>(); //记录所有的极大值和极小值 if (prices.Length <= 1) { r 阅读全文
摘要:
public class Solution { public int FirstUniqChar(string s) { Dictionary<char, int> dic = new Dictionary<char, int>(); foreach (char c in s) { if (!dic 阅读全文
摘要:
https://leetcode.com/problems/sum-of-left-leaves/#/description 补充一个python的实现: 阅读全文
摘要:
https://leetcode.com/problems/intersection-of-two-arrays/#/description 阅读全文