题目链接:
http://www.lydsy.com/JudgeOnline/problem.php?id=1611
题解:
直接bfs。。。
代码:
#include<stdio.h>
#include<string.h>
#include<algorithm>
#include<queue>
#define m (300)
using namespace std;
struct node{
int x;int y;
};
queue<node>q;
node jia(