It takes 1 calorie to raise temp of 1 gram of water by 1° C so 10 calories will raise 10 grams of water by 1° . Thus 100 calories are needed to raise 10 grams of water by 10° C from 20° to 30°
Now 1 calorie = 4.184 J so multiply the 100 calories by 4.184 to determine that 418.4 Joules of energy are needed to complete the task