https://www.acmicpc.net/problem/24479문제풀이DFS는 재귀함수/스택 자료구조로 구현할 수 있다.1. DFS를 시작할 노드를 정한 후 사용할 자료구조 초기화 하기- 인접 리스트로 그래프 표현하기- 방문 배열 초기화 하기 - 시작 노드 스택에 삽입하기2. 스택에서 노드를 꺼낸 후 꺼낸 노드의 인접 노드를 다시 스택에 삽입하기3. 스택 자료구조에 값이 없을 때 까지 반복한다.코드public class Main { static ArrayList[] A; static boolean visited[]; static int[] visitedOrder; static int order=1; public static void main(String[] args) throws IOExce..