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:
All of its digits are or
All numbers formed by consecutive digits of are distinct.
For example, is nice, because the numbers formed by consecutive digits of , which are and , are distinct. However, 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?