The simplest neural network you should know cold
A multilayer perceptron (MLP) is just linear → non-linearity → linear → non-linearity → linear, with the last linear layer producing logits. Every architecture in this quest is a specialization or refinement of this template. CNNs replace the linears with convolutions for images; transformers add attention; recurrent nets reuse the same MLP at every timestep.
For tabular data and many simple regression/classification problems, a 2- or 3-layer MLP with 64–256 hidden units and a sensible activation (ReLU or GELU) is a reasonable starting point. It will rarely beat a tuned gradient-boosted model, but it is the right shape to learn the rest of the field on.
Shapes through an MLP
Track the shapes layer by layer. Input x: [B, in_dim], hidden h₁: [B, hidden_dim], hidden h₂: [B, hidden_dim], output y: [B, out_dim]. The weight matrix that connects two layers has shape [out, in] in PyTorch's convention; the bias has shape [out].
What changes as you add depth and width
Width (more units per layer) gives you more parallel features at one level of abstraction. Depth (more layers) gives you more compositional structure across abstractions. Real networks need a mix. For most tabular problems, two or three hidden layers of moderate width (128–512) is enough; for images and text, depth and specialized architectures dominate.