When, heat is exchanged between a hot and cold object, the temperature of the cold object goes on increasing with the gain of energy, while the temperature
of the hot object goes on decreasing due to loss of energy. This change in temperature goes on till the temperatures of both the objects reach the same value. During this process, the cold object gains heat energy and the hot object loses heat energy. If the environment is separated from the system of both the objects by keeping it inside a heat resistant box (meaning that the energy exchange takes place between the two objects only), then no energy can flow from inside the box or come into the box. Principle applied here is Heat energy lost by the hot object = Heat energy gained by the cold object. This is called the ‘Principle of heat exchange.’