문제https://www.acmicpc.net/problem/17472풀이(40분)import java.io.*;import java.util.*;public class Main { static final int INF = Integer.MAX_VALUE; // 무한대 값 상수로 선언 static int n, m, answer; static int[] parent; static int[][] map; static int[] dx = {0, 0, -1, 1}; // 상하좌우 static int[] dy = {-1, 1, 0, 0}; static int[][] lengthMap; static PriorityQueue pq = new PriorityQueue(); ..