Puzzle 1275
A Python code to analyze a MS in format CVS
Suppos e you are given a Magic square in format CVS.
Here we ask for a Python code that analyze any
magic square and confirm or disconfirm the followin
fatures of the MS:
1) The MS is a true Magic
Square (verifying that all the rows, columns & two
main diagonals, sum up to the same quantity)
2)
Verify that all the elements of the MG is composed
by only distint primes
3) Calculate the smallest
and the largest prime in the MS
4) Report the
value of the central cell, supposing that the MS is
nxn, n=odd.
Q1. Send your best Python
Code (or in any other modern computation language of
your preference).
Notes:
Please send
your code in an attached file to your answer email.
Please work over the
following
MS by Roberto Angelone.