You can complete the square by first getting the form #x^2 + kx = h#.
#x^2 + 5x = -6#
Then just add and subtract a certain value that is equal to #(k/2)^2#. Just remember that the function is #x^2 + kx#, so #k# may be negative, but the added #(k/2)^2# will always be positive.
#x^2 + 5x + (5/2)^2 = (5/2)^2 - 6#
#(x+5/2)^2 = 25/4 - 24/4 = 1/4#
#(x+5/2)^2 - 1/4 = 0#
graph{(x+5/2)^2 - 1/4 [-10, 10, -5, 5]}
If you wanted to solve this:
#(x+5/2)^2 = 1/4#
#x+5/2 = pmsqrt(1/4)#
Thus:
#x+5/2 = pmsqrt(1/4)#
#x = pm(sqrt(1/4)) - 5/2#
#x = pm(1/2) - 5/2#
#x = 1/2 - 5/2 = -2#
#x = -1/2 - 5/2 = -3#
#(-2)^2 + 5(-2) + 6 = 4 - 10 + 6 = 0#
#(-3)^2 + 5(-3) + 6 = 9 - 15 + 6 = 0#
You could just factor, though...
#(x+2)(x+3) = x^2 + 2x + 3x + 6 = x^2 + 5x + 6#