Turning carbon dioxide into sugar requires electrons, which plants and algae extract from water, generating O2 in the process. This carries a high energy cost, but when the environment is oxygen-rich there aren’t any alternatives. Where light is present but O2 absent, however, other sources of electrons become available: hydrogen gas, hydrogen sulfide with its rotten egg smell, and iron ions in solution, among others.

