Carbohydrates are compounds formed by the three elements carbon, hydrogen and oxygen that are in a specific ratio. There are different kinds of carbohydrates, such as monosaccharides, disaccharides and polysaccharides that have different chemical formulas. For example, monosaccharides have the general molecular formula of (CH2O)n.
In this general formula, n can be 3, 5, or 6. Monosaccharides are simple sugars like glucose, fructose and galactose. Disaccharides are made of two monosaccharides and include sucrose and lactose, while polysaccharides consist of many monosaccharides. Examples of polysaccharides are starch and glycogen.
The main functions of carbohydrates are to provide energy to an organism and be the building blocks of other structural components like DNA.