Skip to content

Sunday Times Teaser 3212 – Changes at Chequers

by BRG on April 12, 2024

by Victor Bryant

Published Friday April 12 2024 (link)

I started with a six-by-six grid with a 0 or 1 in each of its 36 squares: they were placed in chequerboard style with odd rows 101010 and even rows 010101. Then I swapped over two of the digits that were vertically adjacent. Then in three places I swapped a pair of horizontally adjacent digits.

In the resulting grid I read each of the six rows as a binary number (sometimes with leading zeros) and I found that three of them were primes and the other three were the product of two different primes. The six numbers were all different and were in decreasing order from the top row to the bottom.

What (in decimal form) were the six decreasing numbers?

From → Uncategorized

6 Comments Leave one →
  1. BRG permalink

    With an improvement suggested by Frits:

  2. Frits permalink

  3. John Z permalink

    • Frits permalink

    • John Z permalink

      The test in line 25:

      is redundant and can be removed. The next two tests in lines 26 and 27 are sufficient to ensure that all values are distinct.

  4. Frits permalink

    I left out more logic as it hardly brought down the run time. However, the unaltered row and the position of the vertical swap can be uniquely identified.

Leave a Reply

Note: HTML is allowed. Your email address will not be published.

Subscribe to this comment feed via RSS