This all stems from the molecules that make up each substance. Metals are electron donors (reducing agents), versus nonmetals that are electron acceptors (oxidizing agents). So, when metals bond with...
the gasoline is used to create small explosions in the cylinder and pushes the pistons out to eventually turn a shaft. In theory, heat is converted into work.