Conveniently, some scientists have already figured out how much heat energy it takes to increase the temperature of one gram of water by exactly 1 degree Celsius. That is called the specific heat of water and it's value is 4.184J/g.
So simply multiply the specific heat with the number of grams and the number of degrees C like this:
