# For what value of p does the quadratic x^2-2px+p+2=0 have exactly one solution?

Feb 18, 2016

$p = - 1$ or $p = 2$

#### Explanation:

The roots of a quadratic $a {x}^{2} + b x + c = 0$ are equal when the discriminant (${b}^{2} - 4 a c$) is equal to $0$

In this case
$\textcolor{w h i t e}{\text{XXX}} a = 1$
$\textcolor{w h i t e}{\text{XXX}} b = - 2 p$
$\textcolor{w h i t e}{\text{XXX}} c = \left(p + 2\right)$

So the discriminant is
$\textcolor{w h i t e}{\text{XXX}} {\left(- 2 p\right)}^{2} - 4 \left(1\right) \left(p + 2\right)$
$\textcolor{w h i t e}{\text{XXX}} = 4 {p}^{2} - 4 p - 8$
which factors as
$\textcolor{w h i t e}{\text{XXX}} = 4 \left(p - 2\right) \left(p + 1\right)$

and the discriminant $= 0$ if
$\textcolor{w h i t e}{\text{XXX}} p = 2$ or $p = - 1$