For a exploding body, linear momentum is conserved.
From conservation of linear momentum
$P_{\text {initial }}=P_{\text {final }} $
$0=m_{1} v_{1}-m_{2} v_{2} $
or $m_{1} v_{1}=m_{2} v_{2} $
or $ \frac{v_{1}}{v_{2}}=\frac{m_{2}}{m_{1}}\,\,\,$...(i)
Thus, ratio of kinetic energies
$\frac{E_{1}}{E_{2}}=\frac{\frac{1}{2} m_{1} v_{1}^{2}}{\frac{1}{2} m_{2} v_{2}^{2}}=\frac{m_{1}}{m_{2}} \times\left(\frac{m_{2}}{m_{1}}\right)^{2} $
$=\frac{m_{2}}{m_{1}}$