Problem 550: (2002 AIME II, 1)
Given that $x$ and $y$ are both integers between $100$ and $999$, inclusive; $y$ is the number formed by reversing the digits of $x$; and $z=|x-y|$. How many distinct values of $z$ are possible?
- Write $x=\overline{abc}$ and $y=\overline{cba}$ with $a,c\ne0$. Then $z=|100a+c-100c-a|=99|a-c|$.
- The difference $|a-c|$ takes the values $0,1,\dots,8$.
- So $z$ takes $9$ distinct values.
- The answer is $\boxed{009}$.
Given that $x$ and $y$ are both integers between $1000$ and $9999$, inclusive; $y$ is the number formed by reversing the digits of $x$; and $z=|x-y|$. How many distinct values of $z$ are possible?