The freezing point of mercury is -38.83°C at 1 atm. So, this means we have to calculate two quantities of heat. The first one is for the sensible heat of bringing down the liquid mercury just before it freezes at -38.83°C.
Q₁ = mCpΔT
where specific heat of liquid mercury, Cp = 0.14 J/g·°C
Q₁ = (18 g)(0.14 J/g·°C)(-38.83 - 25°C)
Q₁ = -160.85 J
The second heat is the latent heat. The heat of fusion of mercury, ΔHfus, is 11.7 J/g.
Q₂ = mΔHfus
Q₂ = (18 g)(11.7 J/g) = 210.6 J
Therefore,
Total heat energy = -160.85 J+210.6 J = 49.75 J