Which is a consequence of the third law of thermodynamics Energy is not always conserved. Engines cannot discharge waste heat. Heat engines are less than 100 percent efficient. Engines produce more waste heat than work.
Heat engines are less than 100 percent efficient because theoretically energy is going to finds another way to be released like sound and pressure release etc.