On heating a gas in a open container (P = constant, V = Constant) some moles of gas goes out.
Thus,
$n_1T_1 = n_2T_2$
$n_1\times300 = n_2\times400$
$n_2 = \large\frac{3n_1}{4}$
$\therefore$ Fraction of moles of gas left
$\Rightarrow \large\frac{n_2}{n_1} = \large\frac{3n_2}{4n_1} =\large\frac{3}{4}$
Hence answer is (a)