How does keeping a carbonated beverage capped help keep it from going "flat"?
The cap on a carbonated beer or soft-drink is GAS TIGHT......and prevents the passage of gas out from the bottle, and out of solution.
Typically, when we bottle beer or ginger beer (for instance) just before capping the bottle we would put a teaspoon or so of sugar in the bottle with the beer, so that the sugar undergoes fermentation in the bottle with residual yeast to form a little bit of ethanol, and also carbon dioxide. The carbon dioxide thus
The bottle is thus pressurized to
If you are doing A levels you should ask your chem teacher (nicely!) if you can brew home brew (beer or ginger beer) in the laboratory. This is fairly simple to do but needs a bit of organizing; the teachers will certainly appreciate your efforts, because after a few weeks they can drink all the beer that you have made.
The picture depicts the crown seals that you typically put on the bottle with a capper; I think you can see the neoprene ring on the inside of the cap, which forms a gas-tight seal with the bottle opening to trap the gas that evolves.