Semiconductors typically use silicon as a base material. Silicon has 14 electrons in three shells. The inner two shells are full with 2 and 8 electrons each. The outermost shell has spots for 8 electrons, but only 4 are present.
With four electrons and four holes, multiple silicon atoms can form a stable configuration, each sharing electrons with neighboring atoms to fill their electron shells.
In a pure crystal of silicon, all atoms share electrons perfectly with all their neighboring atoms. However, other elements can be introduced to the crystal via semiconductor doping to produce extra electrons or extra holes (unfilled spots for an electron). These types of crystals are called n-doped semiconductors (for having a net negative charge due to extra electrons) and p-doped semiconductors (for having a net positive charge due to having a deficit of electrons).
It doesn't take many impurity atoms to create a semiconductor; one impurity atom per half-million silicon atoms will make a reasonable semiconductor. The most common elements used in semiconductor doping are ones with only one extra electron or hole relative to silicon: boron, phosphorous, gallium, and arsenic are all common dopants.
Electrical current flows in a material by causing a cascading jumping of electrons/holes. An electron will enter one side of the material and knock another electron free from its shell, taking its place. That electron will continue in a similar direct and do the same. Eventually, an electron will come out the other end of the material.
- Designing Analog Chips ISBN 978-1589397187