一、
Magic Squares


A magic square of order
n
is an arrangement of
n×n
numbers, usually distinct integers, in a square, such that the
n
numbers in all rows, all columns, and both diagonals sum to the same constant (see Wikipedia:
Magic Square
).

You are to write a Java program (MagicSquare.java) for checking the row/column/diagonal values of a matrix and then judging whether it is a magic square.
判断是否幻方结构:

