有大佬帮忙看看我第三题的代码吗。。卡在30%。是不是不能直接在地图上改,我把visit过的坐标直接改成了井号 。按说BFS模板写过多少次了 不会有错啊。。 核心代码: boolean reach = false; int step = 0; Queue<int[]> queue = new LinkedList<>(); queue.offer(new int[]{x1, y1}); map[x1][y1] = '井&(13607)#39;; while (!queue.isEmpty() && !reach) {     int sz = queue.size();     step++;     for (int i = 0; i < sz; i++) {         int[] cur = queue.poll();         int x = cur[0], y = cur[1];         for (int j = 0; j < 4; j++) {             int newX = x + dir[j][0], newY = y + dir[j][1];             if (newX < 0 || newX >= n || newY < 0 || newY >= m || map[newX][newY] == '井&(13607)#39;) continue;             map[newX][newY] = '井&#39;;             if (Math.abs(newX - x2) <= 1 && Math.abs(newY - y2) <= 1){                 reach = true;             }             queue.offer(new int[]{newX, newY});         }     } } if(reach){     System.out.println(((x1 + 1) * (x2 + 1)) ^ step ^ ((y1 + 1) * (y2 + 1))); } else{     System.out.println(-1); }