My friend gave me this problem which I have not been able to solve:
Let $S(k)$ denote the sum of the digits of $k$. Find all natural solutions $(x,y,z)$ to the equations:
$S(x) + S(y) + S(z) = y-4$
$S(x) + S(y) = x$
$x + y + S(z) = z$
Any help in solving this(I would like to have some hints)?
Edit: Solutions are ok too please.
Note that $x=S(x) \mod 9$ etc.
So $x$ and $y$ are multiples of 9, and $z = 5 \mod 9$.
If $y = 9$ then $y=S(y)$ and the first equation would give $S(x) + S(z) = -4$ which is impossible. So $y \ge 18$.
If $x = 9$ then $x=S(X)$ and the second equation would give $S(y)=0$ which is impossible. So $x \ge 18$.
And $z > x+y$. So $x \in \{18,27,36 \dots\}$, $y \in \{18, 27, 36 \dots \}$, $z \in \{41, 50, 59, \dots \}$.
I'll let you take it from there.