**From New Scientist #2758, 1st May 2010** [link]

On three identical square cards I wrote 3 × 3 magic squares (where the sums of each row, column and major diagonal are equal) using the numbers 1 to 9 on the first, 10 to 18 on the second and 19 to 27 on the third. I formed them into a sandwich in some order. I then found that I could push a pin through the cards so that it passed through three multiples of three. Furthermore, writing the three numbers in order along the pin gave a five-figure perfect square. One number on the middle card was sandwiched between two perfect squares on the other cards.

Which number?

[enigma1593]

### Like this:

Like Loading...

The following Python program runs in 39ms.

Solution:The number on the middle card is 7.