C ++ matrix change animation | Sololearn: Learn to code for FREE!
New course! Every coder should learn Generative AI!
Try a free lesson
0

C ++ matrix change animation

Pre-write in the file a quadratic matrix A of a given size NxN. You need to run the program by reading the matrix from the file and drawing it on the screen. It is required to change the matrix according to the following principle. Move rows and columns to place the largest matrix element in the upper left corner of the matrix in box (1,1). The same equation should be used for the sub-matrix derived from the previous one, excluding the first column and the first row. The largest element of the second submatrix should appear in field (2,2). We continue to form the main diagonal of the matrix. It is necessary to display the movement of every two numbers on the screen to illustrate the described process. The code is needed in c++. I would be very grateful for your help. The animation should be like this. Leave enough space between the elements of the matrix to move the elements around them.

8th Oct 2020, 11:31 AM
Romik Grigoryan
Romik Grigoryan - avatar
2 Answers
0
Attempt it yourself firsts and if you get stuck you can ask something
8th Oct 2020, 12:25 PM
Cat Sauce
Cat Sauce - avatar
0
I can only write a program to create a matrix, but I don't understand anything about the rest, so I didn't write my own code
8th Oct 2020, 3:20 PM
Romik Grigoryan
Romik Grigoryan - avatar