\(f\left(x\right)=0\)
\(\Leftrightarrow x^2-3x-4x+12=0\)
\(\Leftrightarrow x\left(x-3\right)-4\left(x-3\right)=0\)
\(\Leftrightarrow\left(x-3\right)\left(x-4\right)=0\)
\(\Leftrightarrow\left[{}\begin{matrix}x-3=0\\x-4=0\end{matrix}\right.\Leftrightarrow\left[{}\begin{matrix}x=3\\x=4\end{matrix}\right.\)