English
For every list l, the function List.length is continuous at l.
Русский
Для каждого списка l функция длины списка непрерывна в точке l.
LaTeX
$$$ \operatorname{ContinuousAt}(\text{List.length})(l) $$$
Lean4
theorem continuousAt_length : ∀ l : List α, ContinuousAt List.length l :=
by
simp only [ContinuousAt, nhds_discrete]
refine tendsto_nhds ?_ ?_
· exact tendsto_pure_pure _ _
· intro l a ih
dsimp only [List.length]
refine Tendsto.comp (tendsto_pure_pure (fun x => x + 1) _) ?_
exact Tendsto.comp ih tendsto_snd