Carbon's Chemical Bonding
The carbon atom has four electrons in its outer, or valence, shell. This means that every carbon atom can form four, and only four, covalent (electron-pair-sharing) bonds by pairing its four valence electrons with four electrons from other atoms. This includes forming bonds to other carbon atoms, which can form bonds to still other carbon atoms, and so on. Thus, extensive skeleton structures of dozens or hundreds of carbon atoms can be built up.
A carbon atom does not form its four bonds all in the same direction from the nucleus. The bonding electron pairs being all negatively charged tend to repel one another, and they will try to get as far apart as possible. The bonds will therefore stick out in four equally spaced directions. In two dimensions, four equally spaced directions from a point would aim at the four corners of a square. But in three-dimensional space, four equally spaced directions from a point (the carbon atom's nucleus) aim at the four corners of a tetrahedron.
On two-dimensional paper, the formation of a covalent bond between two carbon atoms can be depicted as follows, where the dots indicate valence electrons and the C's indicate the rest of the atoms (nucleus plus inner electrons):
The carbon atoms still have unused bonds shown by the unpaired dots, and they can join to third and fourth carbon atoms and so on, building up longer and longer chains:
Instead of lining up in straight or normal chains, the carbon atoms may also bond in different directions to form branched chains.
In all of these skeletons, there are still some carbon valence electrons that are not being used for carbon-to-carbon bonding. The remaining bonds can be filled by hydrogen atoms to form hydrocarbon molecules:
Hydrogen is a particularly good candidate for bonding to carbon because each hydrogen atom has only one valence electron; it can pair up with one of the carbon atom's valence electrons to form a bond in one of carbon's four possible directions without interfering with any of the other three because hydrogen is such a tiny atom. (In addition to its valence electron, a hydrogen atom is nothing but a proton.) Hydrocarbons are divided into two general classes: aromatic hydrocarbons, which contain benzene rings in their structures, and aliphatic hydrocarbons, which are all the rest.