Her candy bar melted because the second law of thermodynamics which is energy transfer from high to low. Therefore the temperature from the room got inside of the shoe and the temperature from the shoe got into the candy bar which caused it to melt.