How many $3$ digit numbers with digits $a$,$b$ and $c$ have $a=b+c$ My question is simple to state but (seemingly) hard to answer. How many $3$ digit numbers exist such that $1$ digit is the sum of the other $2$. I have no idea how to calculate this number, but I hope there is a simple way to calculate it. Thank you in advance.

EDIT: The first digit should not be $0$
Parameterize those numbers by $\overline {abc}$.

We have three cases, one when the first digit equals the sum of the other two. The second, when the second digit equals the sum of the other two, and so on...



Case I

$\overline {abc}$, $a=b+c$

when $b$ is $0$, $c$ can be $\{1,2,...,9\}$

when   $b$ is $1$, $c$ can be $\{0,1,2,3,...,8\}$ and so on...

$9+9+8+...+1=55-1=54$



Case II

$\overline {bac}$, $a=b+c$

when $b$ is $1$, $c$ can be $\{0,1,...,8\}$ 

when $b$ is $2$, $c$ can be $\{0,1,...,7\}$ and so on...

Now, we've added some numbers here that we've also added in the previous case. Namely, the ones for which $b=a+c$ is true. Since we've added them in this case $b=a-c$ is also true, so $c$ must be $0$. $c$ is $0$ only when $b$ is $\{1,2,...,9\}$. So the final answer for this case is $45-9=36$.



Case III

$\overline {bca}$, $a=b+c$

when $b$ is $1$, $c$ can be $\{0,1,...,8\}$

when $b$ is $2$, $c$ can be $\{0,1,...,7\}$ and so on..

Here we've added again some numbers, namely, for which $b$ is equal $a+c$, in step one. Note that we did not add any numbers that we added in case $2$ since, for those numbers we would have $c=b+a$(from case $2$) and also $c=a-b$(from step $3$). That would make $b$ $0$.(and we did not count that). 

So, the final answer is $45-9=36$, for this case.

In total, we have $126$ numbers with that property.



Those numbers are:
$$\begin{array}{|c|}
\hline
101&amp;
110&amp;
112&amp;
121&amp;
123&amp;
132&amp;
134&amp;
143&amp;
145&amp;
154&amp;
156&amp;
165&amp;
167&amp;
176&amp;
178&amp;
187&amp;\\\hline
189&amp;
198&amp;
202&amp;
211&amp;
213&amp;
220&amp;
224&amp;
231&amp;
235&amp;
242&amp;
246&amp;
253&amp;
257&amp;
264&amp;
268&amp;
275&amp;\\\hline
279&amp;
286&amp;
297&amp;
303&amp;
312&amp;
314&amp;
321&amp;
325&amp;
330&amp;
336&amp;
341&amp;
347&amp;
352&amp;
358&amp;
363&amp;
369&amp;\\\hline
374&amp;
385&amp;
396&amp;
404&amp;
413&amp;
415&amp;
422&amp;
426&amp;
431&amp;
437&amp;
440&amp;
448&amp;
451&amp;
459&amp;
462&amp;
473&amp;\\\hline
484&amp;
495&amp;
505&amp;
514&amp;
516&amp;
523&amp;
527&amp;
532&amp;
538&amp;
541&amp;
549&amp;
550&amp;
561&amp;
572&amp;
583&amp;
594&amp;\\\hline
606&amp;
615&amp;
617&amp;
624&amp;
628&amp;
633&amp;
639&amp;
642&amp;
651&amp;
660&amp;
671&amp;
682&amp;
693&amp;
707&amp;
716&amp;
718&amp;\\\hline
725&amp;
729&amp;
734&amp;
743&amp;
752&amp;
761&amp;
770&amp;
781&amp;
792&amp;
808&amp;
817&amp;
819&amp;
826&amp;
835&amp;
844&amp;
853&amp;\\\hline
862&amp;
871&amp;
880&amp;
891&amp;
909&amp;
918&amp;
927&amp;
936&amp;
945&amp;
954&amp;
963&amp;
972&amp;
981&amp;
990&amp;\\\hline
\end{array}
$$



For verification, the code is:

 #include&lt;iostream&gt; 

 using namespace std;

 int main() {
         int q=0;
         for(int a=1;a&lt;=9;a++)
             for(int b=0;b&lt;=9;b++)
                 for(int c=0;c&lt;=9;c++)
                         if(a==b+c || b==a+c || c==a+b)

{q++;cout&lt;&lt;a&lt;&lt;b&lt;&lt;c&lt;&lt;"\n";}

 cout&lt;&lt;q; return 0; }


This, in case you do not allow $2-digit$ or $1-digit$ numbers.
For some, this might not be the most intuitive way, but it is a way to solve this problem.

If $a=b+c$, then if a is an even number it gives us 2 exceptions, and if a is odd it gives 1 exception. Will keep exceptions in a seperate bucket.

The maximum sum that can be reached is 9. 
So if $(b,c,a)$ represent the set of possible number then, 
$(1,8,9),(2,7,9),(3,6,9),(4,5,9)$ and then $b,c$ change place. That's $4\times 2 =8$ numbers. And since places are not fixed, therefore its $8\times3=24$ numbers + 1 exception $(909)$

Now, For 8  $(1,7,8),(2,6,8),(3,5,8)$ that's $3\times2\times3=18$ numbers +2 exceptions $(448,808)$

For 7  $(1,6,7),(2,5,7),(3,4,7)$ that's $3\times2\times3=18$ numbers +1 exception $(707)$

For 6  $(1,5,6),(2,4,6)$ that's $2\times2\times3=12$ numbers +2 exception $(606,336)$

For 5  $(1,4,5),(2,3,5)$ that's $2\times2\times3=12$ numbers +1 exception $(505)$

For 4  $(1,3,4)$ that's $2\times1\times3=6$ numbers +2 exception $(404,224)$

For 3  $(1,2,3)$ that's $2\times1\times3=6$ numbers +1 exception $(303)$

So far, 96 numbers. Now, lets look at the combinations of number put in exception and will count and add seperately.
$(909,990,448,844,484,808,880,707,770,606,660,336,363,633,112,121,211,202,220,101,110)$

Total count of number :$117$