please tell how to implement this program in java
Q2.Magic Squares.An n*n matrix that is filled with the numbers 1,2,...,n*n is a
magic square if the sum of the elements in each row ,in each column,and in the
two diagonals is the same value . For example
16 3 2 13...