
1. Determine all triples of positive integers $(a, b, n)$ that satisfy the following equation:

$$
a !+b !=2^{n}
$$

Notation: $k !=1 \times 2 \times \cdots \times k$, for example: $1 !=1$, and $4 !=1 \times 2 \times 3 \times 4=24$.


1. Since $a$ and $b$ play the same role in the equation $a !+b !=2^{n}$, we will assume for simplicity that $a \leqslant b$. The solutions for which $a>b$ are found by interchanging $a$ and $b$. We will consider the possible values of $a$.

Case $a \geqslant 3$ : Since $3 \leqslant a \leqslant b$, both $a$ ! and $b$ ! are divisible by 3 . Hence $a$ ! $+b$ ! is divisible by 3 as well. Because $2^{n}$ is not divisible by 3 for any value of $n$, we find no solutions in this case.

Case $a=1$ : The number $b$ must satisfy $b !=2^{n}-1$. This implies that $b$ ! is odd, because $2^{n}$ is even (recall that $n \geqslant 1$ ). Since $b$ ! is divisible by 2 for all $b \geqslant 2$, we must have $b=1$. We find that $1 !=2^{n}-1$, which implies that $n=1$. The single solution in the case is therefore $(a, b, n)=(1,1,1)$.

Case $a=2$ : There are no solutions for $b \geqslant 4$. Indeed, since $b$ ! would then be divisible by $4,2^{n}=b !+2$ would not be divisible by 4 , which implies that $2^{n}=2$. However, this contradicts the fact that $2^{n}=b !+2 \geqslant 24+2$.

For $b=2$, we find $2^{n}=2+2=4$. Hence $n=2$ and $(a, b, n)=(2,2,2)$ is the only solution.

For $b=3$, we find $2^{n}=2+6=8$. Hence $n=3$ and $(a, b, n)=(2,3,3)$ is the only solution. By interchanging $a$ and $b$, we obtain the additional solution $(a, b, n)=(3,2,3)$.

In all, there are four solutions: $(1,1,1),(2,2,2),(2,3,3)$ and $(3,2,3)$.
