Table with four coins

[This problem has crossed the desk of Jan van de Snepscheut, but it may have been due to someone else.]

A square table has a coin at each corner. Design an execution sequence, each of whose steps consists of one of the following operations:

  • ONE: The operation chooses a coin (possibly a different one with each execution of the operation) and flips it.
  • SIDE: The operation chooses a side of the table and flips the two coins along that side.
  • DIAG: The operation chooses a diagonal of the table and flips the two coins along that diagonal.

such that at some point during the execution (not necessarily at the end), a state where all coins are turned the same way (all heads or all tails) obtains.

©2019 K.R.M. Leino - Split Template by One Page Love