Finding a four digit number I came across this problem today and couldn't figure out a way to work it out in a cogent manner. Also, if anyone knows what type of algebra this is conceptually so I can look up similar problems more accurately in the future, that would be awesome. Here's the question:
A four-digit integer, $WXYZ$, in which $W$, $X$, $Y$, and $Z$ each represent a different digit, is formed according to the following rules:
$$X = W + Y + Z$$
$$W = Y + 1$$
$$Z = W - 5$$
What is the four digit integer?
Thanks in advance!
 A: The possible digits (presumably, we are working in base 10) are $0$, $1$, $2$, $3$, $4$, $5$, $6$, $7$, $8$, and $9$.
We will use the fact that if $A$ is a digit, then $0\leq A\leq 9$.
Because $Z$ is a digit, we have that $Z\geq 0$. Because $Z=W-5$, we have that $W-5\geq 0$, or equivalently, $W\geq 5$. Because $W$ is a digit, we have that $W\leq 9$. Therefore, $W$ can only be one of the following numbers: $5$, $6$, $7$, $8$, or $9$.
Because $Z$ is a digit, we have that $Z\geq 0$. Also, recall $W=Y+1$. Therefore, 
$$X=W+Y+Z\geq W+Y= 2W-1.$$ Because $X$ is a digit, we have that $X\leq 9$. Therefore, we have to have that $2W-1\leq 9$, hence $2W\leq 10$, hence $W\leq 5$. But, combining this with our previous conclusions about $W$, this means that the only option for $W$ is 5.
Thus, $$Y=W-1=4,\quad Z=W-5=0,\quad X=W+Y+Z=9,$$ so the number is $5940$.
A: $X,Y,Z,W$ are all digits and hence lies between $0$ and $9$. Substitute $Y$ and $Z$ in equation for $X$ in terms of $W$.That gives $X=3W-6$.But, $Z\geq 0 \implies W\geq 5$(from 3rd equation) and $X\leq9 \implies 3W-6\leq 9 \implies W\leq5$.Therefore,$W=5$.Therefore,$X=3W-6=9$, $Y=W-1\implies Y=4$ and $Z=W-5\implies Z=0$.Therefore, the number is $5940$.
