Within neural networks, memories are defined by the presence of two distinct layers: an input layer and an output layer. The interconnection between neurons in the input layer and those in the output layer occurs through synapses, whose weight determines whether the activation of a neuron in the input layer is linked to that of a neuron in the output layer.