Problem

Source: 2021 Peru Ibero TST P3

Tags: combinatorics



A whole number is written on each square of a $3\times 2021$ board. If the number written in each square is greater than or equal to at least two of the numbers written in the neighboring squares, how many different numbers written on the board can there be at most? Note: Two squares are neighbors when they have a common side.