How many solutions does $x^2 + 3x +1 \equiv 0\, \pmod{101}$ have? $x^2 + 3x +1 \equiv 0 \pmod{101}$. To solve this I found the determinant $D = 5 \pmod{101}$). Using the Legendre symbol,
$$\left(\frac{5}{101}\right) = \left(\frac{101}{5}\right) \equiv \left(\frac{1}{5}\right) \equiv 1,$$
$\therefore$ The equations have a solution.
My question is how I can find out how many solutions it has?

For prime  $p$: If $A$ is a square modulo $p,$ take any B such that $A\equiv B^2\pmod p.$ Then $$x^2\equiv A \pmod p\iff (x-B)(x+B)\equiv x^2-B^2\equiv 0 \pmod p\iff$$ $$\iff (\;p|(x-B)\lor p|(x+B)\;)\iff x\equiv \pm B \pmod p.$$  If $A\not \equiv 0 \pmod p,$ then $B\not \equiv 0\pmod p.$  If $p\ne 2,$ and $B\not \equiv 0 \pmod p$ then $B\not \equiv -B \pmod p.$ So for $p\ne 2$ and $A\not \equiv 0\pmod p$  there are, modulo $p,$ exactly $2$ solutions to $x^2\equiv A \pmod p,$ which  are $x\equiv \pm B \pmod p.$
In your Q you are looking for solutions to $(2x+3)^2\equiv 5 \pmod {101}.$  Take any $B$ such that $B^2\equiv 5 \pmod {101}.$ Then $(2x+3)^2\equiv B^2 \iff 2x+3\equiv \pm B \pmod {101},$ which implies there exactly $2$ values, modulo $101$, for $x$.
