Let $X$ be an infinite dimensional vector space and $N$, $M$ be subspaces of $X$ such that $N \subseteq M$. Suppose $\dim(X/M)=\dim(X/N) \lt \infty$. Show that $$N=M$$ holds.
I know that above holds if $X$ is finite dimensional by using the dimension theorem to show $\dim(N)=\dim(M)$. However, I do not see a way in the infinite dimensional case.
Any help is appreciated.