Here is a 4X4 matrix randomly generated and between 0 and 9 :
Refresh to have a new matrix
7
4
7
4
7
2
0
7
5
7
0
3
9
7
0
8
The average of the first row is 5.5
The average of the second row is 4
The average of the third row is 3.75
The average of the fourth row is 6
The average of the first column is 7
The average of the second column is 5
The average of the third column is 1.75
The average of the fourth column is 5.5