Given a 2d matrix of size N x M (which must be read from a fileprovided to you), transpose it into a M x N matrix where N is thenumber of rows and M is the number of columns.
void transpose(int n, int m, const int A[n][m], intAT[m][n]);
Write a main() program to test and demonstrate your function.Show your function works for, at minimum, 3×6 and 10x6matrices.
Expert Answer
An answer will be send to you shortly. . . . .