摘要: 桌游制造 我们可以对于每种图案记录拥有这种图案的有那些圆片,然后我们枚举每一个圆片,枚举这个圆片上面的图案,枚举拥有这种图案的圆片还有哪些,然后分别打上标记,如果有一个圆片明明已经有标记了,然而又要被打一次标记,那么我们可以直接输出 \(NO\) 如果标记都已经打完了,可还是有节点没被打到也是 \( 阅读全文
posted @ 2024-10-03 20:55 libohan0518 阅读(3) 评论(0) 推荐(0) 编辑
摘要: 缩进优化 我们可以枚举 \(i\) 的所有倍数,我们让每一块中的数除以 \(i\) 相等,显然这是调和集数 #include <bits/stdc++.h> using namespace std; #define int long long const int N = 1e7 + 5, INF = 阅读全文
posted @ 2024-10-03 20:31 libohan0518 阅读(1) 评论(0) 推荐(0) 编辑
摘要: 跳蚤os 我们可以考虑使用线段树 #include <bits/stdc++.h> using namespace std; const int N = 1e6 + 5; struct node { int son[27]; } trie[500005]; struct F { int x; str 阅读全文
posted @ 2024-10-03 00:11 libohan0518 阅读(3) 评论(0) 推荐(0) 编辑