Introduction
Computers are built from tiny logic gates — AND, OR, NOT — combined in huge numbers. In 1943, McCulloch and Pitts showed that simple artificial neurons can act as these gates. That was a big idea: if neurons can do logic, then networks of neurons can, in principle, compute anything a computer can.
But one innocent-looking gate, XOR ("exclusive or"), can't be built from a single neuron. Understanding why — and how a second layer fixes it — is the clearest way to see why neural networks need hidden layers.