Bdmo 2014 question? $N$ is a number that consists of $2012$ digits. If you take any consecutive $m$ digits $(m \leq 2012)$ from $N$ starting from any position in that number, there'll be another position in $N$ so that the $m$ consecutive digits starting from that position will be in the reverse order of the former one. The total number of possible values of $N$ can be written as $a \times 10^{b}$ where $a$ and $b$ are positive integers, $a$ is not divisible by $10$. What is the value of $a+b$?
It's a problem from BdMO 2014. I have no idea about how to approach this kind of problems (because I'm a beginner). Please help me solve it. And sorry if it's too easy.


$N$ must satisfy problem statement at any $m\leq 2012$. None number $N$ can satisfy this problem statement is we understand "another position" as "not the same position", then let understand "another position" as "some position" (Problem statement 1). Another option is consider "another position" as "not the same position" but change $m\leq 2012$ (impossible) to $m\leq 2011$ (Problem statement 2). These problem statements are equivalent.
In problem statement 1 $N$ must be palindromic to satisfy case $m=2012$. In problem statement 2 $N$ must be palindromic to satisfy case $m=2011$. Palindromic $N$ will satisfy all cases $m\leq 2011$ in both problem statements.
Then one needs only calculate count of possible palindromic numbers $N$ with 2012 digits. That is the same as count of 1006-digit numbers (I suppose first digit of $N$ cannot be zero), which is $10^{1006}-10^{1005}=9\cdot 10^{1005}$. Then $a+b=1014$.
