import java.util.ArrayList; public class Solution { // 四中状态的 enum Status { LeftToRight, TopToBottom, RightToLeft, BottomToTop } private int[][] init(int row, int col) { int[][] visited = new int[row][col]; for (int i = 0; i < visited.length; i++) { ...