Consider a sequence $\left(u_{n}\right)$ with the first term $u_{0}$ and for all natural numbers $n$:

$$
u_{n+1}=a u_{n}+b
$$

Express the $n^{\text{th}}$ term of the sequence in terms of $u_{0}$
There are two cases. If $a=1$, the sequence $\left(u_{n}\right)$ is simply defined by $u_{n+1}=u_{n}+b$. Thus

$$
\begin{aligned}
u_{n}-u_{0} & =\left(u_{n}-u_{n-1}\right)+\left(u_{n-1}-u_{n-2}\right)+\ldots+\left(u_{2}-u_{1}\right)+\left(u_{1}-u_{0}\right) \\
& =b+b+\ldots+b+b \\
& =n b
\end{aligned}
$$

And we can directly deduce that $u_{n}=u_{0}+n b$. If $a \neq 1$, then we start by showing that $1+a+a^{2}+a^{3}+\ldots+a^{n}=\frac{1-a^{n+1}}{1-a}$. Indeed, we notice that:

$$
(1-a)\left(1+a+a^{2}+\ldots a^{n}\right)=\left(1+a+a^{2}+\ldots+a^{n}\right)-\left(a+a^{2}+\ldots a^{n+1}\right)=1-a^{n+1}
$$

Then, we can start looking at the first terms of the sequence $\left(u_{n}\right)$:

$$
\begin{aligned}
& u_{1}=a u_{0}+b \\
& u_{2}=a\left(a u_{0}+b\right)+b=a^{2} u_{0}+b(1+a) \\
& u_{3}=a\left(a^{2} u_{0}+b(1+a)\right)+b=a^{3} u_{0}+b\left(1+a+a^{2}\right)
\end{aligned}
$$

We can therefore conjecture that for all $n, u_{n}=a^{n} u_{0}+b\left(1+a+\ldots+a^{n}\right)=a^{n} u_{0}+b \frac{1-a^{n+1}}{1-a}$. We will prove this conjecture by induction on $n$. The initialization corresponds to $u_{0}=u_{0}$. We assume that the formula is true for $n \geq 0$ and we show that it is true for $n+1$. By the induction hypothesis, we have $u_{n}=a^{n} u_{0}+b \frac{1-a^{n+1}}{1-a}$. Therefore:

$$
\begin{aligned}
u_{n+1} & =a u_{n}+b \\
& =a\left(a^{n} u_{0}+b \frac{1-a^{n+1}}{1-a}\right)+b \\
& =a^{n+1} u_{0}+b\left(a \frac{1-a^{n+1}}{1-a}+1\right) \\
& =a^{n+1} u_{n+1}+b \frac{a+1-a-a^{n+2}}{1-a} \\
& =a^{n+1} u_{n+1}+b \frac{1-a^{n+2}}{1-a}
\end{aligned}
$$

Therefore, the property is true for $n+1$, which concludes the proof.