 Hello friends, I am Sanjay Bhokta. I welcome you on Sanjay Bhokta Tech School. In this video, I am going to tell you how you can correct algorithm for the empty transpose of a matrix. So, I am going to start writing the algorithm. So, the name of the algorithm will be Transpose. It will be receiving three parameters. So, first is A that will be a 2D array. Second is number of rows that are applicable in that 2D array and C means number of columns that are applicable in that 2D array. Now, step number one. So, start. Then, step number two. So, from step number two, we will start to do. So, I am writing the P, I, so it will be for I equals to 1 to row. Then, one more loop will be required so that we can iterate for the columns. So, the P for J equals to 1 to column. And here we can write print A of J. So, normally, whenever we print a matrix for the use A of IJ, but in case of transpose, we need to print rows in column heights or you can say column in row heights. So, for that purpose, we need a J I location. So, first we need to use column index and then we need to do it. Then here you can write end of loop. So, this is for this loop. Then again you need to write end of loop so that you can mark this is for this loop. So, here both the loops are ended and then you can write step number three matrix N. Now, let's take the matrix. These are values. Name of matrix is A and number of columns are three and number of columns are three. So, here you can see I is starting from one. So, initially I is one and controls will be transferred to J. So, J is also one. R and C both are 3D. So, first time we will be printing A of 1, 1 position. So, A of 1, 1 position is this. So, remember one thing, we are discussing algorithm. So, in case of algorithm, we consider indexes are starting from one, not from zero. Because whenever you will be implementing this algorithm with any programming address, then you need to consider that indexes are starting from two. But in case of algorithm, indexes are also starting from one only. So, A of 1, 1 position means one will be printed as output. So, it will be printed. Then J will be implemented. So, value of J will get two. So, here I implemented algorithm to all. So, here you can see J is two. So, next time two, one position will be printed. So, two, one position is this, four. So, it will be printed. Then, value of J will be one, three. So, it will print J, three, one. So, three, one is this, seven. So, this way you can see a column is printed. So, first column is printed. Then, second column will be printed. So, this way, through changing this Aij, Aji, you can print your matrix transpose. So, this is a simple algorithm to which you can print transpose or matrix or 2Di. So, this is an algorithm. If you want to watch its program like how it will be implemented in three languages. So, for that, you need to go to description of this video. Then you will find a link of playlist that has data structure you can see. So, you can follow that playlist. So, here I have uploaded all the videos. Those will be implemented algorithm with the help of C, language. So, who was that? And I hope you understood how we can print transpose or matrix and how we can write their algorithm with the help of this video. Thank you for watching this video.