Proof verification (sets & logic) Question:
Let $f$: $\mathbb{N} \rightarrow \mathbb{Z}$ be a function that is eventually zero. i.e: There exists some $N \in \mathbb{N}$ s.t  $f(n)=0$ for all $n \geq \mathbb{N}$. Prove that the set of such functions is countable.
Proof:
Define $g$: $\mathbb{N} \rightarrow \mathbb{Z}$ s.t $$
g(i) = \left\{
        \begin{array}{ll}
            f(i) & \quad i \in \{0,1…N-1\} \\
            0 & \quad  , otherwise
        \end{array}
    \right.
$$
Let $B_n=\{h|h: \{0,1…N-1\}\rightarrow \mathbb{Z}$}. Clearly, $B_n$ is equal to $N$ copies of $\mathbb{Z}$. Hence, it's countable.
Let $G=\{f|f: \mathbb{N}\rightarrow \mathbb{Z}\}$ is eventually zero}.
So, $G = \cup_{N=1}^{\infty} B_n$. Countable union of countable sets is countable. So is $G$.
Is my approach correct?
 A: The basic idea is good, but you rather want to take the union of $G_N$'s where
$$G_N:=\{f:\Bbb N\to\Bbb Z:f(n)=0\text{ if } n>N\}$$
A: Your proof is correct. Here are some points of feedback.


*

*Your definition of $g$ depends on a specific $f$ and is actually just the same as that $f$. It does not really do anything in your proof, so just leave it out.

*It is not quite true that $G = \bigcup_{N=1}^\infty B_n$, because the maps in $B_n$ do not have domain $\mathbb{N}$. They can however easily be made into maps with domain $\mathbb{N}$ (which is clearly what you mean), you should say this (and how).

*A few small issues with notation, it is a bit sloppy. There is a $\}$ too many in the definition of $G$. The set $B_n$ depends on $n$ not on $N$ in its notation. That kind of thing. Not really a problem here, but in bigger proofs it will get confusing.

A: I think there is a problem defining the map $g$...What you call $f$ is actually a set of functions....And also you do not use $g$ after you define it...
Some hint, How many maps from $\Bbb{N}$ to $\Bbb{Z}$ can you construct that they are zero after $n=0$ or after $n=1$,.....? 
