Splice the left ends of the kernel-cokernel exact sequences$0 \to \ker(f) \to \ker(gf) \to \ker(g) \to \mathrm{cok}(f) \to \mathrm{cok}(gf) \to \mathrm{cok}(g) \to 0$and$0 \to \ker(g) \to \ker(kg) \to \ker(k) \to \mathrm{cok}(g) \to \mathrm{cok}(kg) \to \mathrm{cok}(k) \to 0$,noting that $\ker(kg) = \ker(h)$, $\mathrm{cok}(f) = 0$ and $\mathrm{cok}(g) = 0$.The kernel-cokernel sequence for a composition appears in Milne's Arithmetic Duality Theorems (Proposition 0.24), Short exact sequences every mathematician should know and https://arxiv.org/abs/2001.07528 , but must be about as old as the snake lemma.
↧