I was given the following assertion:
If $X$ and $Y$ are Hausdorff, $X$ is compact, and $f:X\to Y$ is continuous and surjective, then $f$ is open.
However, I believe that I have a counterexample:
Define $f:[0,3]\to[0,2]$ by
$$ x\mapsto\begin{cases} x&0\leq x\leq1,\\ 1&1<x<2,\\ x-1&2\leq x\leq3. \end{cases} $$
Then $[0,3]$ and $[0,2]$ are Hausdorff, $[0,3]$ is compact, and $f$ is continuous and surjective. However, $[0,3/2)$ is open in $[0,3]$ but $f([0,3/2))=[0,1]$ is not open in $[0,2]$.
Does this look correct? If so, then is there a similar theorem?
There are some more or less similar theorems: