The mass and energy both are conserved in an isolated system", is the statement of modified first law of thermodynamics. According to this law, if a certain amount of one kind of energy is produced, an equal amount of some other kind of energy is consumed so that the total energy in the universe remains constant.