let $\displaystyle \{a_i \}_{i \in I},$ where $\displaystyle a_k=1$ for some $\displaystyle k \in I,$ be a basis for $\displaystyle \mathbb{R},$ as a vector space over $\displaystyle \mathbb{Q}.$ that means every element of $\displaystyle \mathbb{R}$ can be written

*uniquely* as $\displaystyle \sum_{i \in I} r_ia_i,$ where $\displaystyle r_i \in \mathbb{Q}$ and all but at most finitely

many of $\displaystyle r_i$ are zero. define $\displaystyle f: \mathbb{R} \longrightarrow \mathbb{Q}$ by $\displaystyle f \left(\sum_{i \in I} r_ia_i \right)=r_k.$ the map $\displaystyle f$ is clearly well-defined and satisfies the conditions a) and b). to show that it also satisfies the condition c), choose $\displaystyle i \in I$

such that $\displaystyle i \neq k$ and also choose a sequence $\displaystyle \{s_n \} \subset \mathbb{Q}$ such that $\displaystyle \lim_{n \to \infty} s_n = \frac{1}{a_i}.$ now define $\displaystyle x_n=a_k - s_na_i$ and see that $\displaystyle \lim_{n \to \infty}f(x_n)=1$ but $\displaystyle f( \lim_{n\to\infty} x_n)=0.$