I want to show that the function $$f=\left\{\begin{matrix} 0, \text{ if } x \in [0,1)\\ 1, \text{ if } x \in (1,2] \end{matrix}\right.$$ is continuous but not uniformly continuous at $[0,1) \cup (1,2]$.
A function $f:A \rightarrow \mathbb{R}$ is continuous at a point $x_0$: $ \forall ε > 0$, $\exists δ > 0$ such that $\forall x \in A$ with $$|x-x_0|<\delta \Rightarrow |f(x)-f(x_0)|<\epsilon\tag 1$$ In this case do I have to show that the function is continuous at $[0,1)$ and then at $(1,2]$? But how can I show that it is continuous at an interval using the definition $(1)$? Do I have to take $x_0 \in [0,1)$ for any $x$ to show that the function is continuous at $[0,1)$ and then a $x_0 \in (1,2]$ for any $x$ to show that the function is continuous at $(1,2]$??