For example, the contents of a pressure cooker on a stove with its lid tightly closed and the whistle in position, is a closed system as no mass can enter or leave the pressure cooker, but heat can be transferred to it. When the whistle of the pressure cooker blows, then it becomes an open system as steam leaves the cooker