Prove/Disprove there exists only one continuous function $f:\mathbb{R} \to \mathbb{Z}$ I know that every function $f: \mathbb{Z} \to \mathbb{R}$ is continuous.
This can be proven by Weierstrass' $\varepsilon$-$\delta$ criterion. If $f:E\subseteq \mathbb{R} \to \mathbb{R}$ is continuous at $x_0 \in E$, then $$\forall \varepsilon > 0 \exists \delta > 0 \forall x \in E \left( \left| x - x_0\right| < \delta \to \left| f(x) - f(x_0)\right| < \varepsilon \right)$$ Let $E := \mathbb{Z}$ and $\varepsilon > 0$, $x_0 \in E$ be fixed. Taking $\delta := 1$, we get, that the only point which fulfills $\left| x - x_0\right| < \delta$ is $x_0$ itself, but then trivially $$\left| f(x_0) - f(x_0)\right| = 0 < \varepsilon$$ holds. Since $x_0 \in E$ was arbitrary, $f$ is continuous on $E$.
But how can one prove/disprove that there exists only one continuous function:
$$f:\mathbb{R} \to \mathbb{Z}$$
 A: Hint: Is it not the case that $f:\mathbb{R}\to \mathbb{Z}$ given by $f(x)=1$ and $g:\mathbb{R}\to \mathbb{Z}$ given by $g(x)=0$ are both continuous?
A: Any constant function $\mathbb{R} \to \mathbb{Z}$ is continuous, so this claim is definitely false.

But these are the only counterexamples:
Indeed, suppose we are given a continuous function $f: \mathbb{R} \to \mathbb{Z}$. Since $\mathbb{R}$ is connected, we have that $f(\mathbb{R})$ is a connected subspace of $\mathbb{Z}$. The only connected subspaces of $\mathbb{Z}$ are singeltons, so $f$ must necessarily be constant.
A: There are many ways to show that a continuous $f:\Bbb R\to \Bbb Z$ must be constant. We can consider $f$ to be continuous from $\Bbb R$ into $\Bbb R$ and use some general properties of all continuous real functions. For example, the Intermediate Value Property: Suppose $f:\Bbb R\to \Bbb R$ is continuous and not constant. Then there are $x,x'$ with $f(x)\ne f(x').$ Now for every $y$ between $f(x)$ and $f(x'),$ there exists $x''$ between $x$ and $x'$ such that $f(x'')=y.$ But there is always some $y$ between $f(x)$ and $f(x')$ with $y\not \in \Bbb Z;$ therefore it is not possible that $\{f(x''):x''\in \Bbb R\} \subseteq \Bbb Z.$
