For the question,
$$F(x)= x^{2} + 6x + 20 + k(x^{2} -3x -12)$$
I have to find the value of k and the value of $p$ given that the minimum value of $F(x)$ is $p$ and $F(-2) = p$.
What I did is: I expanded the expression of $F(x)$ and reached a term for $p= 12 - 2p$. I tried to complete the square of the two quadratics of $F(x)$ separately then added the two terms while also correcting for coefficients. I doubt this operation however went for it anyway due to any alternatives seem wrong.
I reached the term $-\frac {39}4k + 11$ then promptly equated it to $12 - 2k$.
I reached the value of $-\frac{4}{31}$ for $K$.
My textbook has answers for $k = \frac{2}{7}$ and $p=\frac{80}{7}$.
You can try completing the square directly. Notice that the minimum of $F(x)$ lies at $x = -2$, and $F(-2) = p$. This means that
$$F(x) = a(x + 2)^2 + p$$
for some constant $a$. We can't assume $a = 1$ because any non-zero value of $a$ can work, so we leave it there as it is.
Now we go ahead and solve as usual by comparing coefficients:
$$a(x + 2)^2 + p = x^2 + 6x + 20 + k(x^2 - 3x - 12)$$ $$ax^2 + 4ax + (4a + p) = (k + 1)x^2 + (6 - 3k)x + (20 - 12k)$$
Comparing coefficients, we have
$$k + 1 = a~~~~,~~~~4a = 6 - 3k~~~~,~~~~4a + p = 20 - 12k$$ Firstly, $$4a = 6 - 3(a - 1)$$ $$4a = 9 - 3a$$ $$7a = 9$$ $$a = \frac{9}{7}$$ Secondly, $$\begin{align}k &= a - 1 \\&= \frac{9}{7} - 1 \\&= \frac{2}{7}\end{align}$$ And lastly, $$4a + p = 20 - 12k \implies 4\cdot\frac{9}{7} + p = 20 - 12 \cdot\frac{2}{7}$$ $$p = \frac{80}{7}$$