TeX source:
\begin{aligned} \frac{p}{q} &=\frac{\text { factor of constant term }}{\text { factor of leading coefficient }} \\ &=\frac{\text { factor of } 3}{\text { factor of } 3} \end{aligned}