To find the heat/energy required to raise he temperature of a substance, use this formula:
Q=mcΔT
Q= heat (J)
m= mass of substance (g)
c= specific heat of substance (J/g°C; depends on the substance; you're usually given this or you'll have to look it up)
ΔT= change in temperature (°C)
for this question:
m = 7g; c (water) = 4.186 J/g°C; ΔT= 16 °C
∴ Q= 7g x 4.186 J/g°C x 16 °C =468.832 J