Answer :
The condition for the perfect square of a quadratic equation is given as:
[tex]b^2-4ac=0[/tex]From the question;
[tex]\begin{gathered} x^2+18x=0 \\ a=1,\text{ b=18, c=?} \\ \end{gathered}[/tex]To obtain c, we have;
[tex]\begin{gathered} b^2-4ac=0 \\ 18^2-4(1)c=0 \\ 324-4c=0 \\ 4c=324 \\ c=\frac{324}{4} \\ c=81 \end{gathered}[/tex]The complete version of the equation becomes:
[tex]\begin{gathered} x^2+18x+81=0 \\ (x+9)^2=0 \end{gathered}[/tex]Hence, the correct option is Option B