Satyam is so obsessed with dancing that he can dance with anything. Today he is dancing with a matrix of dimensions N by N where a[i][j] is defined by the following equation:
a[i][j] = ((i)^j)%17 where x^y is equivalent to x raised to the power y
where i and j indices of the matrix follows 1-based-indexing.
Here are his dance moves:
Matrix1 : each row should contain the cumulative sum of the corresponding row in the original matrix.
Matrix2 : each column should contain the cumulative sum of the corresponding column of the original matrix
Your Input : 5
NOTE You do not need to create a program for this problem you have to write your answers of given input in given code snippet
Compile and Test can give Wrong Answer. Once you have written your answer, print Submit button to check your result.
The matrix formed as per the equation is :
1 1 1 1 1 2
2 4 3 5 2 6
Original Matrix 1 Matrix 2
Product of the matrix :
3 8
13 36