260

#include <iostream> #include <map> #include <stack> #include <queue> #include <string> #include <cstring> #define INF 1000000000 using namespace std; string row[205]; bool trace[205][205]; int N; struct node{ int x; int y; }; int floodFillDfs(node a) { //stack<node> s; queue<node> s; map<int,int> mp; s.push(a); int i,j; int r =0; while(!s.empty()) { node t= s.front();//s.top(); s.pop(); i=t.x; j=t.y;