Write a program to find transpose of a square matrix mat of size N*N. Transpose of a matrix is obtained by changing rows to columns and columns to rows.
The first line of input contains an integer T, denoting the number of testcases. Then T test cases follow. Each test case contains an integer N, denoting the size of the square matrix. Then in the next line are N*N space separated values of the matrix.
For each test case output will be the space separated values of the transpose of the matrix
1 <= T <= 15
1 <= N <= 20
-103 <= mat[i][j] <= 103