백준 2468번 C++
#include #include #include using namespace std; const int MAX = 101;int n;int arr[MAX][MAX];int visited[MAX][MAX];typedef struct {int a, b;}Move;Move mv[4] = { {1,0},{-1,0},{0,1},{0,-1} }; void dfs(int i,int j,int h) {for (int k = 0; k = 0 && mi = 0 && mj h && visited[mi][mj] == -1) {visited[mi][mj] ..
2019. 2. 25.