The Cantor set $C$ is perfect, hence all it points are limit points. Then for every $x\in C$ exists at least a sequence such that $(x_n)\to x$. Then it make me think that the definition of (dis)continuity (at any point $x$) can be applied here, that is
$$\forall \epsilon>0,\exists \delta>0:|y-x|<\delta\implies |f(x)-f(y)|<\epsilon$$
But, at the same time, by the induced topology from $\Bbb R$ is clear that any subset of $C$ is open and closed, hence $f$ is trivially continuous. Can someone clarify this question? Thank you.
Let $c\in C$ be a point in the Cantor set and define $f:C\to\mathbb R$ by $$f(x)=\left\{\begin{array}{ll}0&\mbox{ if }x=c\\2&\mbox{ otherwise }\end{array}\right .$$ Then $f^{-1}((-\infty,1))=\{c\}$, and since $c$ is a limit point of $C$ it cannot be open. Thus $f$ is not continuous.