Countability of set of functions from $\mathbb{Q}$ to $ \left \{0,1 \right \}$ under some conditions The question given is check Whether following is countable or not

$1).$The set of all the functions from $\mathbb{Q}$ to $\left \{0,1  \right \}$
$2).$The set of all the functions from $\mathbb{Q}$ to $\left \{0,1  \right \}$ which vanish outside a finite set

solution i tried- In $1$ option we can see that number of functions is $2^{\aleph_0}$  which is uncountable 
But for $2$ option i am not getting clue how to proceed  further  Seems like he is asking about the cardinality of set of    compact support functions .
Please help 
Thank you
 A: For each $n$, show that the set of functions from $\mathbb{Q}$ to $\{0,1\}$ that vanish outside a finite set of $n$ elements is countable. From here can you conclude that your set is countable?
For example, when $n=1$, we're looking for the functions that vanish at all but one point $x\in \mathbb{Q}$. Then we can easily see that there are two varieties of a such functions: (1) $f(y)=0$ for all $y\in\mathbb{Q}$, or (2) $f(y)=0$ for all $y\neq x$ and $f(x)=1$. Thus there are two functions for each $x\in \mathbb{Q}$, so this set is countable.
A: I would say that the cardinality of functions from Q to {0,1} is uncountable in both cases as, taking the first case, for a specific q, $f(q)$ could take any real value between 0 and 1 and this set is uncountable - each member of the range is a separate function.
If we restrict the range to 0 for a finite set of Q, say $q_1, q_2… q_n$, then for another rational point, say $q_0$, the function at that point $f(q_0)$ can still take an uncountable range of real values.
