A Hilbert space is separable if and only if it has a countable orthonormal basis.
Proof. Assume that $\{ e_j\}$ is an orthonormal basis for the Hilbert space $H$. By Theorem (i), it is easy to show that the countable subset of elements $x$ with $\langle x,e_j \rangle$ in the set of rationals for all $j$ is dense. Thus, $H$ is separable.
Theorem (i). Every element $x$ of a Hilbert space $H$ with an orthonormal basis $\{ e_j\}$ can be expressed in terms of the Fourier expansion
$$x=\sum\limits_{j=1}^\infty \langle x,e_j \rangle e_j.$$
Question: I don't understand the sentence "By Theorem (i), it is easy to show that the countable subset of elements $x$ with $\langle x,e_j \rangle$ in the set of rationals for all $j$ is dense."