Skip to main content

Explain backpropagation in simple terms.

Deep learning · Intermediate 2

Short answer

Backpropagation works out how much each weight contributed to the error. After a forward pass computes the prediction and loss, it applies the chain rule backwards, layer by layer, to get the gradient of the loss for every weight. An optimiser such as gradient descent then nudges each weight in the direction that reduces the loss.

Deeper answer

Think of a long chain of simple functions. The chain rule says the effect of an early weight on the final loss is the product of the local effects along the path. Backpropagation computes these efficiently by reusing results from later layers as it moves back, so getting every gradient costs only a small multiple of one forward pass, not one pass per weight.

Frameworks such as PyTorch do this automatically: they record operations during the forward pass and call backward to fill in gradients. You still need to understand it to diagnose problems such as vanishing or exploding gradients, and to know why you zero gradients between steps.

What a strong answer covers

Answer it out loud in the mock interview about 1.5 min

Follow-ups to expect

Common mistakes

Learn it

Neural networks

Today's AI turns are used

Lessons, roadmaps, videos, practice cards and the code playground stay free with your account, with no limit.