IMO 2016 Shortlist C4

Find all positive integers n for which we can fill in the entries of an n × n table with the following properties: • eac...

IMO 2016 Shortlist C4

Category: Combinatorics

Problem

Find all positive integers n for which we can fill in the entries of an n × n table with the following properties: • each entry can be one of I, M and O; • in each row and each column, the letters I, M and O occur the same number of times; and • in any diagonal whose number of entries is a multiple of three, the letters I, M and O occur the same number of times.