All you have to know is
( a + b )² = ( a + b ) ( a + b )
In this case,
Since "a" is negative, make it into positive for easier simplification.
(-2x-1)² = 0
-(2x+1)² = 0
-[(2x+1) (2x+1)] = 0
Negative got eliminated when divided to 0
Thus,
x = -1/2 , x = -1/2