As we know that,
$P=\frac{V^{2}}{R}$
$\Rightarrow R=\frac{V^{2}}{P}$
$\Rightarrow R \propto \frac{1}{P}$
Hence, the resistance of $25\,W$ bulb is greater than the resistance of $100\, W$ bulb
Now, both the bulb are joined in series so the current will be same
So, heat produced by the bulbs
$H =i^{2}Rt$
$\Rightarrow H \propto R$
So, the heat produced by the $25\,W$ bulb is greater than the bulb of $100\, W$, because its resistance is more than that of $100\, W$ bulb
Hence, $25 \,W$ bulb will glow brighter