$M$ is an $A$-module for some ring $A$.
My approach: suppose $\ell(M) < \infty$ because otherwise the proposition is trivial.
Let $0 = M_r \subsetneq M_{r-1} \subsetneq ... \subsetneq M_0 = M$ be a composition series for $M$.
Then $0 = \pi(M_r) \subset \pi(M_{r-1}) \subset ... \subset \pi(M_0) = M/N$
Let's prove this is a composition series for $M/N$.
We have $\pi(M_i)/\pi(M_{i+1}) = \frac{M_i/N}{M_{i+1}/N}$ and by the second isomorphism theorem, $\frac{M_i/N}{M_{i+1}/N} \approx M_i/M_{i+1}$, which is simple because it comes from a composition series of $M$.
I strongly suspect this proof is not correct as I'm proving that the lengths are equal...but I don't see the mistake.
Oh, I understood! $N$ is not necessary inside $M_i$ so more work is necessary.