백준 1012 유기농 배추 / java 자바
www.acmicpc.net/problem/1012 1012번: 유기농 배추 차세대 영농인 한나는 강원도 고랭지에서 유기농 배추를 재배하기로 하였다. 농약을 쓰지 않고 배추를 재배하려면 배추를 해충으로부터 보호하는 것이 중요하기 때문에, 한나는 해충 방지에 www.acmicpc.net import java.util.*; public class Main { static int[][] map; static boolean[][] ck; static Queue q; static int N, M, K; static int[] dx = {0, -1, 0, 1}; static int[] dy = {-1, 0, 1, 0}; static void bfs(int x, int y) { q.add(new int[]{x, y}..