The expression can be rewritten as \displaystyle x^2+2\cdot 3\cdot x+3^2 and then we see that it can be factorized, using the squaring rule \displaystyle x^2+2ax+a^2=(x+a)^2, as
Vorlage:Displayed math