$x=1 \pmod 8$
$x=5 \pmod{12}$
8 and 12 are not coprime, I could break it to:
$x=1 \pmod 2$
$x=1 \pmod 4$
and
$x=5 \pmod 3$
$x=5 \pmod 4$
But what are the next steps to solve it? By the way, $x$ should be $17$ not sure how to get that number ...
Thanks in advance.
Here is a way: $$\begin{cases} x\equiv 1\pmod 8\\x\equiv 5\pmod{12} \end{cases}\iff \begin{cases} x -1\equiv 0\pmod 8\\x -1\equiv 4\pmod{12}\end{cases}\iff \begin{cases} \frac{x -1}4\equiv 0\pmod 2\\\frac{x -1}4\equiv 1\pmod{3} \end{cases}$$
Now set $y=\frac{x-1}4$. As $3-2=1$, the solutions of the last system of congruences is $$ y\equiv 0\cdot 3- 1\cdot 2 =-2\pmod{6},$$ so that, multiplying by $4$, $$x-1\equiv -8 \iff x\equiv -7\iff x\equiv 17\pmod{24}$$