Receptors in the skin detects a stimulus. Then Sensory neurons send electrical impulses to a relay neuron which is located on the spinal cord of the CNS. Motor neurons send electrical impulses to an effector.
Effector produces a response (muscle contracts to move hand away.
I'm going to kill you!
Yay! Its dead !!
Motor neuron - Directly control all of muscle movements. That's why my arms and legs (basically my whole body ) Jumped when I saw the cockroach. Sensory neurons - Carry signals from the outer part of the body to the CNS. This allowed my Motor neuron to work.
Association neurons - Acts like a link between sensory neurons and motor neurons. (located in the spinal cord)