Why can't I use $U=\frac32 pV$ to find overall change in internal energy of the gas? The physics question goes like this:

An ideal gas undergoes an expansion in volume from $1.3\times 10^{-4}\:\rm m^3$ to $3.6\times10^{-4}\:\rm m^3$ at a constant pressure of $1.3\times10^5\:\rm Pa$. During this expansion, $24\:\rm J$ of heat is supplied to the gas.
What is the overall change in the internal energy of the gas?

Now I managed to find the correct answer (decrease of $6\:\rm J$) using the change in $U=q+w$ method. However I also learnt that $U=\frac32 pV$ but applying the equation to find the change in internal energy does not give the same answer,
$$\frac32 \times 3.6\times 10^{-4}\:\mathrm{m}^3 \times 1.3\times 10^5\:\mathrm{Pa} - \frac32 \times 1.3\times 10^{-4}\:\mathrm{m}^3 \times  1.3\times 10^5\:\mathrm{Pa} =44.85.$$
Side question: How can an ideal gas at the same pressure but has expanded to a higher volume have lower internal energy? It seems very counterintuitive.
 A: What has happened here is that the gas has experienced an irreversible expansion, in which the pressure of the gas in its initial equilibrium state was much higher than 1.3E5 Pa.  However, at time zero, the external pressure on the gas was suddenly and discontinuously dropped to 1.3E5 Pa, and the gas was then allowed to expand irreversibly and equilibrate at this constant external pressure to the new final volume.  Of course, we know that the work done on the gas in this process was $W=-P_{ext}\Delta V = -30 J$. And, since the heat added was 24 J, the change in internal energy was -6 J.  We can use this information to determine the value that the gas pressure had just before the external pressure was suddenly dropped to the new value of 1.3E5.  We can still use your equation, but we write $$\Delta U=\frac{3}{2}(P_fV_f-P_{init, gas}V_i)=\frac{3}{2}\left((1.3\times10^5)(3.6\times 10^{-4})-P_{init, gas}(1.3\times 10^{-4})\right)=-6$$The solution to this equation for $P_{init, gas}$ is $P_{init, gas}=3.9\times 10^5$ Pa.  So at time zero, the external pressure on the piston is suddenly dropped from the internal gas pressure of $3.9\times 10^5$ Pa to the lower pressure of $1.3\times 10^5$ Pa and held at that value until the gas equilibrates.
A: Agree: counter-intuitive, and, I think, impossible. The only way the gas volume can increase at constant pressure is if it gets hotter, so U increases.
I suspect that this is an ineptly constructed question. However, assuming that it had been properly constructed, here's the answer to your main question...
The internal energy of an ideal monatomic gas (such as helium) is $\frac{3}{2}nRT=\frac{3}{2}pV$. But for a diatomic gas (e.g. hydrogen, oxygen, nitrogen} it is approximately $\frac{5}{2}nRT=\frac{5}{2}pV$, and in general there are different numeric factors according to atomicity and shape of molecule. So, since the question didn't tell you the atomicity you must use the First Law approach – which you did.
