摘要:
SPOJ_1771 通过这个题目进一步训练了Dancing Links解决N皇后问题的技巧。#include<stdio.h>#include<string.h>#include<stdlib.h>#define INF 1000000000const int MAXN = 50;const int MAXmn = MAXN * MAXN * 4 + MAXN * 6 + MAXN;const int MAXnn = MAXN * 6 + MAXN;int N, size;int U[MAXmn], D[MAXmn], L[MAXmn], R[MAXmn], 阅读全文