Question: Write a program that reads an input matrix and creates one output matrix and displays it. - Input matrix has to be provided by the

Write a program that reads an input matrix and creates one output matrix and displays it. - Input matrix has to be provided by the user using input function only once (the input function is not used in the loop). - The input matrix must be a square matrix. If this is not true, the program displays "matrix not square" and stops. - Rewrite the rows of the input matrix into the output matrix alternating with the vector of zeros i.e. rewrite first row of input matrix into first row of output matrix, into the second row of the output matrix write only zeros, then rewrite the second row from the input matrix into the third row of the output matrix etc. You have to use loops to do so. See the example below: input matrix 1: 113 260 898 result matrix: 113 000 260 000 898 000 Write your program in virtual development lab called "TASK 1
Step by Step Solution
There are 3 Steps involved in it
Get step-by-step solutions from verified subject matter experts
