The x term has a coefficient of 4. Take half of this to get 2, then square it to get 4. This is the value we add to both sides to get x^2+4x+4 = 5. Note how x^2+4x+4 factors into (x+2)^2
---------
Another example: Let's say we started with x^2+6x = 1. To complete the square, we need to add 9 to both sides. I start with 6 (the x coefficient) and cut that in half to get 3, then I squared that to get 9. So we add 9 to both sides getting x^2+6x+9 = 10 which becomes (x+3)^2 = 10