Prove that $S = \{ f: [0,1]\rightarrow \mathbb{R} \ \text{continuous} : x\in\mathbb{Q}\implies f(x) \in \mathbb{Q}\}$ is. uncountable Prove that
$$S = \{ f: [0,1]\rightarrow \mathbb{R} \ \text{continuous} : x\in\mathbb{Q}\implies f(x) \in \mathbb{Q}\}$$ is uncountable.
I know that reals are uncountable,  so I look for injection from reals to set $S$, i.e., if we can define a function as above for each real number, then we are done.
Am I going in the right direction?
Please help with some hint/solution.

HINT:
For every $a\in \{0,1\}^{\mathbb{N}}$ consider
$f_a(\frac{1}{n}) = \frac{1}{2n + a_n}$, $1\mapsto 1$, $0\mapsto 0$, and extend by linearity.
