随笔分类 - 之前的比赛题目
摘要:重点在阅读理解能力 身份证号必须是18位数字,话说平时咱们身份证也可以带个X啥的啊。 合法状态就是只要身份证合格就行,一开始我还想是它犯病,然后申请了口罩才算一个合法记录。 后边输出状态为1的人,一定要按照每个人犯病顺序输出,也就是说如果某个人一开始没犯病,后边犯病了,那取它在后边的顺序。 这样模拟
阅读全文
摘要:#include <bits/stdc++.h> using namespace std; int cal(int a, int b, char c) { int t; if (c == '/' && b == 0) t = -1; else if (c == '+') t = a + b; els
阅读全文
摘要:#include <bits/stdc++.h> using namespace std; const int N = 1010; int main() { ios::sync_with_stdio(false); cin.tie(0); int n, m, k; cin >> n >> m >>
阅读全文
摘要:并没有说根是谁 #include <bits/stdc++.h> using namespace std; using pii = pair<int, int>; const int N = 1E5 + 10; vector<int> g[N]; int depth[N]; bool flag[N]
阅读全文
摘要:需要注意的地方: 我们只记录维京人的祖先,除了维京人的其他人不能记录它的祖先 #include <bits/stdc++.h> using namespace std; struct people { string name, familyname; char gender; }; map<stri
阅读全文
摘要:#include <bits/stdc++.h> using namespace std; bool isyifu[10010]; bool isunhappy[10010]; bool ishappy[10010]; int tran(int x) { int res = 0; while (x)
阅读全文
摘要:时隔一年再回来写这道题,发现的确好简单。 #include <bits/stdc++.h> using namespace std; using ll = long long; int z(char C) { return C - 'a'; } set<string> all; vector<int
阅读全文
摘要:90行,调了俩小时,大约有以下坑点。 1.每个数字都可能正负出现,比如-0 0,-1 1,一开始以为一个数的正负只会出现一个。 2.当俩人都不出现在照片中,那么输出俩人就行 3.当其中一个人不在照片里的时候,那个不在照片里的人不用输出,一开始以为既然是情侣,所以不在照片里的那个那么肯定和自己的对象最
阅读全文
摘要:#include <bits/stdc++.h> using namespace std; using ll = long long; int main() { int n, g, k; cin >> n >> g >> k; vector<tuple<string, int>> score(n);
阅读全文
摘要:#include <bits/stdc++.h> using namespace std; using ll = long long; const int N = 100010; vector<int> g[N]; int main() { int n; cin >> n; int root = -
阅读全文
摘要:#include <bits/stdc++.h> using namespace std; using ll = long long; const int N = 10010, M = N * 2; vector<int> g[N]; int main() { int n, m; cin >> n
阅读全文
摘要:#include <bits/stdc++.h> using namespace std; constexpr int N = 2E4 + 10; int f[N]; int find(int x) { if (x != f[x]) return f[x] = find(f[x]); return
阅读全文
摘要:并不一定是连通图 #include <bits/stdc++.h> using namespace std; vector<int> g[510]; int main() { int v, e, k; cin >> v >> e >> k; for (int i = 0; i < e; i++) {
阅读全文
摘要:离谱,给的节点中可能还有多余的节点,谜语人 #include <bits/stdc++.h> using namespace std; #define val first #define nex second int main() { ios::sync_with_stdio(false); cin
阅读全文
摘要:#include <bits/stdc++.h> using namespace std; int main() { int n; cin >> n; vector<tuple<string, int, int>> all; for (int i = 0; i < n; i++) { string
阅读全文
摘要:#include <bits/stdc++.h> using namespace std; using ll = long long; const int N = 1e5 + 10; vector<int> G[N]; int main() { int n; double h, r; cin >>
阅读全文
摘要:#include <bits/stdc++.h> using namespace std; using ll = long long; int main() { int n; cin >> n; set<string> S; for (int i = 0; i < n; i++) { string
阅读全文
摘要:#include <bits/stdc++.h> using namespace std; #define e first #define c second constexpr double eps = 1e-8; int main() { int n; cin >> n; map<int, dou
阅读全文
摘要:#include <bits/stdc++.h> using namespace std; int main() { int n; cin >> n; vector<int> a(n + 1); for (int i = 1; i <= n; i++) { cin >> a[i]; } sort(a
阅读全文
摘要:要记得他父母也有性别 #include <bits/stdc++.h> using namespace std; constexpr int N = 1e5 + 10; vector<int> g[N]; int main() { int n, m; cin >> n; map<int, char>
阅读全文

浙公网安备 33010602011771号