MathDB
nice number with digits 1 or 2 only

Source: 1st Girls in Mathematics Tournament 2019 p3 (Brazil) / Torneio Meninas na Matematica (TM^2 )

May 25, 2020
number theoryDigits

Problem Statement

We say that a positive integer N is nice if it satisfies the following conditions: \bullet All of its digits are 11 or 22 \bullet All numbers formed by 33 consecutive digits of NN are distinct. For example, 121222121222 is nice, because the 44 numbers formed by 33 consecutive digits of 121222121222, which are 121,212,122121,212,122 and 222222, are distinct. However, 1212112121 is not nice. What is the largest quantity possible number of numbers that a nice number can have? What is the greatest nice number there is?