import java.util.*; public class Solution { public int[][] rotateMatrix(int[][] mat, int n) { int[][] result = new int[mat.length][mat.length]; Stack<Integer> newRow; for (int i = 0; i < mat.length; i++) { newRow = getColumn(mat, i); for ...