pressure–volume work
Pressure–volume work is the energy a gas spends pushing the world back as it expands — or the energy the world spends squeezing the gas as it shrinks. Think of a cylinder capped by a piston: when the gas inside swells, it shoves the piston out against whatever presses on it, and that shove is real work, energy handed from gas to surroundings. When the surroundings press in and compress the gas, the energy flows the other way.
Its size depends on two things: how hard the surroundings push (the external pressure) and how much the volume changes. Against a steady outside pressure, the work is the external pressure multiplied by the volume change, w = −p_ext ΔV (negative when the gas expands and does work outward). A gas expanding into a vacuum, with nothing to push against, does no work at all — there is no resistance for it to overcome.
This is the most common form of work in chemistry, because so many reactions make or consume gases. It is precisely this push-against-the-atmosphere that enthalpy was invented to absorb, so that at constant pressure the heat we measure already has the pV work folded in.
When you bake bread, carbon dioxide bubbles expand against the surrounding dough and air, pushing the loaf to rise. The expanding gas is doing pressure–volume work on its surroundings.
Any expanding gas that pushes its surroundings outward is doing pV work.
The work depends on the external pressure the gas pushes against, not its own internal pressure. This is why a slow, near-reversible expansion (pushing against an almost-matching pressure) extracts the most work, while a sudden expansion into low pressure yields less — a key idea behind maximum work and efficiency.