Question d’entretien chez SAP

Write a program to check if the provided 2D array is a magic square.