A gas inside a piston-cylinder assembly undergoes the following sequence of processes: