Problem

Source:

Tags: number theory



A number is capicua if it is read equally from left to right as it is from right to the left. For example, $23432$ and $111111$ are capicua numbers. (a) How many $2023$-digit capicua numbers can be formed if you want them to have at least $2022$ equal digits? (b) How many $2023$-digit capicua numbers can be formed if you want them to have at least $2021$ equal digits?