Earthworms are of the phylum Annelida, which is made up of worms with Segmented bodies. The nervous system of the earthworm is segmented like the rest of its body. Also like most annelids. their brains are relativel simple in structure consisting of a bilobed mass lying above the pharynx. The brain and the ventral nerve cord form the central nervous system 0f the earthworm . Earthworms have touch, light and chemical receptors along their entire body surface. The nerves that run along the body wall pass between the outer and inner muscle layers of the earthworm. Pairs of ganglia at intervals along the body control the actions of each body segment.The ventral nerve cord is capable of rapid conduction of impulses to the segmental muscles, enabling the worm to contract rapidly in defense against predators.