Computer Science, asked by dharshan3131, 4 months ago

The program must accept an integer matrix of size R*C as the input. The program must reverse every second column
in the matrix. Then the program must print

Answers

Answered by raghakeshini05
4

Answer:

Input:  1    2   3   4

       5    6   7   8

       9   10  11  12

       13  14  15  16

Output: 1 2 3 4 8 12 16 15 14 13 9 5 6 7 11 10  

Explanation: The output is matrix in spiral format.  

Input:  1   2   3   4  5   6

       7   8   9  10  11  12

       13  14  15 16  17  18

Output: 1 2 3 4 5 6 12 18 17 16 15 14 13 7 8 9 10 11

Explanation :The output is matrix in spiral format.

Explanation:

Similar questions