Let $A$ be an integral domain, $\mathfrak{p}$ a prime ideal of $A$. Let $f(X)=a_nX^n+...+a_1X+a_0$ be a primitive and non constant polynomials of $A[X]$. We also suppose that $a_k \in \mathfrak{p}$ for all $k\in \{0,...,n-1\}$ and $a_n \not \in \mathfrak{p}$. We write $f=gh$ with $g,h \in A[X]$ non constants.
Wlog let's write $g(X)=b_mX^m + ...+ b_1X+b_0$ and $h(x)=c_lX^l +...+c_1X +c_0$, with $l,m\ge 1$ and $l+m=n$.
We then look at the previous equality in $(A/\mathfrak{p})[X]$ and we obtain that : $\overline{f}=\overline{gh}=\overline{f}.\overline{g}$ hence $\overline{a_n}X^n=\overline{f}.\overline{g}$.
We want to prove that $\overline{g}=\overline{b_m}X^m$ and $\overline{h}=\overline{c_l}X^l$.
Now in my lecture, it is suggested that as the ring $A/\mathfrak{p}$ is an integral domain we could work in its fraction field $F_{A/\mathfrak{p}}$.
Hence the equality seen in $F_{A/\mathfrak{p}}[X]$ gives automatically (by fields property) that $\overline{g}= \overline{b_m} X^m$ and $\overline{h}=\overline{c_l} X^l$ with $\overline{b_m}, \overline{c_l} \in (F_{A/\mathfrak{p}})^{\times}, \ l,m\ge 1$ and $l+m=n$.
But is it really necessary to work with the fraction field of $A/\mathfrak{p}$ here ?
I mean, if we work on the integral domain $(A/\mathfrak{p})[X]$, we write : $\displaystyle \overline{a_n}X^n=\left(\sum_{r=0}^{m}\overline{b_r}X^r\right).\left(\sum_{j=0}^{l}\overline{c_j}X^j\right)=\overline{b_m}.\overline{c_l}X^{m+l}+\left(\sum_{r=1}^{m-1}\overline{b_r}X^r\right).\left(\sum_{j=1}^{l-1}\overline{c_j}X^j\right) +\overline{b_0}.\overline{c_0}$.
Hence matching coefficients, using the hypothesis on the $a_k$ and using property of integral domains enable us to deduce by induction that for instance, all the $\overline{b_r}=0$ for $r\in\{0,m-1\}$. But on the other hand all the $\overline{c_j}$ for all $j\in\{0,...,l-1\}$are not necessarily $\overline{0}$ and $\overline{h}$ would not be of the form $\overline{h}=\overline{c_l}X^l$.
So do we use the fraction field to ensure that the divisors of $X^n$ are of the form $X^{t}$ with $t\in\{1,...,n-1\}$ here ?
Thanks in advance !