Transposes a 2D matrix (array of arrays).
The 2D array to transpose.
The transposed 2D array.
This function assumes that the input matrix is well-formed, meaning that it has at least 1 element and all inner arrays have the same length.
Transposes a 2D matrix (array of arrays).