摘要:
思路:把每个点拆成(d+1)*n列,行数为可拆分区间数。对所有的有i号点拆分出来的行都要建一条该行到i列的边,那么就能确保有i号点拆出来的行只能选择一行。#include#include#include#include#include#include#include#include#include#include#define pb push_back#define mp make_pair#define Maxn 1010#define Maxm 80002#define LL __int64#define Abs(x) ((x)>0?(x):(-x))#define lson(x) 阅读全文
摘要:
思路:裸的DLX重复覆盖#include#include#include#include#include#include#include#include#include#include#define pb push_back#define mp make_pair#define Maxn 51#define Maxm 80002#define LL __int64#define Abs(x) ((x)>0?(x):(-x))#define lson(x) (xK) return false; if(R[0]==0) return true; int i,j,temp,c; t... 阅读全文