摘要:
题目链接 题解: 如果不考虑长度限制,可以用二分图染色做。 #include <bits/stdc++.h> # define LL long using namespace std; int n; int a[2001]; int col[2001]; struct Edge{ int to; i 阅读全文
摘要:
题目链接 和leetcode一道题很像。。。 #include <bits/stdc++.h> # define LL long using namespace std; const int INF=0x7fffffff; const int maxn=50002; int n; int f[max 阅读全文