题意:A-K分别代表不同的水管接口,问有多少个不联通的水管。
思路:暴搜
#include <iostream>
#include <cstdio>
#include <cstring>
#include <algorithm>
#include <cmath>
#include <queue>
using namespace std;
const int N = 59;
int n,m;
char map[N][N];
int num[]={2,2,2,2,2,2,3,3,3,3,4};
int mm[][5]={
{0,1},
{0,3},
{1,2},
{2,3},
{0,2},
{1,3},
{0,1,3},
{0,1,2},
{1,2,3},
{0,2,3},
{0,1,2,3}
};
void init()
{
for(int ......
阅读全文