Closed subspace consisting of continuous functions in $L^{2}([0,1])$ is finite-dimensional

From the last line $$ C^2≥ \|g_t\|^2_{2} = \sum_{h \in S} | \langle h, g_t \rangle |^{2} = \sum_{h \in S} |h(t)|^{2} $$ so \begin{align} \infty &> \int_0^1 C^2 \, dx\\ &\geq \int_0^1 \sum_{h \in S} |h(t)|^{2} \, dx\\ &= \sum_{h \in S} \int_0^1 |h(t)|^{2} \, \\ &= \sum_{h \in S} \|h\|^2 = \#S. \end{align}


Here is an interesting consequence of the above fact:

It is known that for a bounded operator $T:H\to K$, between Hilbert spaces $H$ and $K$, the following are equivalent:

  1. $T$ is compact,

  2. the range of $T$ has no infinite dimensional closed subspaces.

While thinking about the present question I first tried to answer it by applying the above fact to the inclusion map $$ T:C([0,1])\to L^2([0,1]), $$ so it would be enough to show that $T$ satisfies (1), above. However I later noticed that $T$ is NOT compact, the reason being that the functions $$ e_n(x) = \sqrt2\sin(2\pi nx), \quad x\in [0,1], $$ form a bounded set in $C([0,1])$, but they do not admit a convergent sub-sequence in $L^2([0,1])$, as they form an orthonormal set in the latter space.

Of course I was wrong all along, as the equivalence between (1) and (2) is stated above only for Hilbert spaces!

While it is not hard to show that (1) implies (2) for all Banach spaces, the present question and answer provide a counter example for (2) $\Rightarrow$ (1) in the context of Banach spaces, as we now know that the range of $T$ contains no infinite dimensional closed subspaces, and yet $T$ is not compact!

Summarizing, the point I want to make is this:

There are non-compact bounded operators between Banach spaces whose range contains no infinite dimensional subspaces, even though no such operators exist between Hilbert spaces.