摘要:
122. 糖果传递 写法一: #include <iostream> #include <algorithm> #include <cstring> using namespace std; typedef long long LL; const int N = 1e6 + 10; int n; L 阅读全文
摘要:
13. 找出数组中重复的数字 class Solution { public: int duplicateInArray(vector<int>& nums) { if(nums.empty()) return -1; unordered_map<int, int> hash; int n = nu 阅读全文
摘要:
AcWing PAT甲级树专题 1476. 数叶子结点 #include <iostream> #include <cstring> using namespace std; const int N = 110; int h[N], e[N], ne[N], idx; int n, m; int c 阅读全文