# continuous but not homeomorphism betwen Hausdorff space and compact Hausdorff space

I am searching for an example of a Hausdorff space $(X,\tau)$ and a compact Hausdorff space $(Y,\sigma)$ with a continuous bijection $f:X\rightarrow Y$ which is not a homeomorphism.

First of all I wrote

$$\mathbb{R}^*_+ \rightarrow [0,1]$$ $$x \rightarrow \frac{1}{x}$$ which is homeomorphism, but i couldnt get any idea about how the answer can be, any help please?

The classical example is $$f \colon [0, \, 2 \pi) \longrightarrow S^1, \quad x \mapsto (\cos x, \, \sin x).$$

This is clearly a continuous bijection, but it is not a homeomorphism since it is not an open map.

The identity from $[0,1]$ endowed with the discrete topology (every set is open) to $[0,1]$ with its usual topology does the job.

Of course, the example of Francesco Polizzi is much nicer and much more important. The advantage of such "trivial" examples is rather to see very quickly and easily that a certain statement cannot be true.