What would be the final temperature of 100 g of 20C water when 87 g of 40C iron nails are submerged in it?

What would be the final temperature of 100 g of 20°C water when 87 g of 40°C iron nails are submerged in it? (The specific heat of iron is 0.12 cal/g °C. Here you should equate the heat gained by the water to the heat lost by the nails.)