On the outside, bacterial cells are generally surrounded by two protective coverings: an outer cell wall and an inner cell membrane. However, certain bacteria, like the mycoplasmas do not have a cell wall at all. Some bacteria may even have a third, outermost, protective layer called the capsule. Lastly, bacterial surfaces can be covered by whip-like extensions: flagella or pili. According to the authors of "Mims Medical Microbiology, 5th Ed" (Saunders, 2013), long flagella aid in motility while short pili help bacteria to attach to host surfaces.