Let $X$ and $Y$ be Hausdorff spaces and suppose that $Y$ is locally compact. Let $f:X\to Y$ be a surjective map such that for any compact subset $K \subset Y$ the pre-image $$f^{-1}(K)=\{x\in X: f(x)\in K\}$$ is a compact subset of $X$. What can I tell about the continuity of $f$?

If $Y$ is compact, then $f$ is certainly continuous if we restrict $f$ to the pre-image of a compact, that is, $f|_{f^{-1} (K)}$, then it is continuous. Can I conclude anything else?

together withcontinuity) $\endgroup$ – erz Aug 30 '18 at 0:52