void goUp(int[][] matrix, int i, int j) {
        if (i < upperBound) return;
        else {
            while (i >= upperBound) {
                int cur = matrix[i][j];
                result.add(cur);
                i--;
            }
            leftBound++;
            goRight(matrix, i + 1, j + 1);
        }
    }