Fermat's theorem (stationary point)
At the very top of a hill, the ground is momentarily level: walk a tiny step either way and you go down, so right at the peak the slope is zero. Fermat's theorem makes this picture exact: a smooth function that attains a high point or low point in the interior of its domain must have zero slope there.
Statement: if f is defined on an interval, has a local maximum or local minimum at an interior point c, and is differentiable at c, then f'(c) = 0. Proof sketch: at a local maximum the difference quotient (f(c + h) - f(c)) / h is at most 0 for small h > 0 and at least 0 for small h < 0; since f is differentiable the two one-sided limits agree and equal f'(c), forcing f'(c) = 0.
Three hypotheses do real work and dropping any one breaks it. The extremum must be interior: on [0, 1] the function f(x) = x has its maximum at the endpoint x = 1 with f'(1) = 1, not 0. The function must be differentiable at c: f(x) = |x| has a minimum at 0 but no derivative there. And the converse is false — f'(c) = 0 does not guarantee an extremum, as f(x) = x^3 shows at 0.
A point where f'(c) = 0 is called a stationary point; Fermat's theorem says interior extrema are stationary, but stationary points need not be extrema.