Transpose of matrix | Sololearn: Learn to code for FREE!
New course! Every coder should learn Generative AI!
Try a free lesson
0

Transpose of matrix

Can anyone tell me how can we find transpose of matrix in O(n) time.

13th Jan 2022, 11:08 PM
umesh ramlod
umesh ramlod - avatar
1 Answer
+ 2
What is `n` in this case? Finding the transpose of a n*m matrix is always going to take O(n*m), since you have to touch every element and move it somewhere else.
14th Jan 2022, 1:28 AM
Schindlabua
Schindlabua - avatar