Recently, while reading a number theory textbook for Olympiads, i came across the following property;
$S(n_1+n_2) \le S(n_1) + S(n_2)$
Where S(A) is the sum of digits of A in base 10. In my textbook, there was a proof given but i couldn't follow it at all.
So I am looking for a proof of the following property and hopefully some reasoning behind it.
Any help would be appreciated, thanks!
Assume $$a = 10^0a_0 + 10^1a_1+10^2a_2+... \\ b = 10^0b_0 + 10^1b_1+10^2b_2+... $$then$$ S(a) = a_0+a_1+... \\ S(b) = b_0+b_1+... \\ \implies S(a)+S(b) = (a_0+b_0)+(a_1+b_1)+...$$ Also, $$a+b = 10^0(a_0+b_0) + 10^1(a_1+b_1)+... \\ a+b =:c = 10^0c_0 + 10^1c_1+10^2c_2+...$$ then $S(a+b) = c_0+c_1+...$
Now
Therefore, $$c_0 + c_1 +... \le (a_0+b_0)+(a_1+b_1)+... $$ or $$S(a+b) \le S(a) + S(b)$$ as desired.