Define the function $f : \{n \mid n = 3m − 1 \text{ for some } m \in \mathbb{Z}\} \rightarrow \{k \mid k = 4m + 2 \text{ for some } m \in \mathbb{Z}\}$ by $f(n)=\frac{4(n+1)}{3}-2$ Prove that $f$ is a bijection.
I am aware that I need to prove $f$ is injective and surjective and therefore, a bijection. How should I approach this? (The lecturer has written "Backwards proof" on my script and marked my answer as incorrect)
Edit (my answer as requested in comments)
Edit2 (switched incorrectly labelled domain and codomain)
if $f(x) = f(y)$ then $\frac{4(x+1)}{3}-2 = \frac{4(y+1)}{3}-2$ $x = y \text{ }$ Therefore the function is injective.
Let $m \in \mathbb{Z} \text{, } 3m-1 \in \mathbb{D} \text{ (domain)}$ $m+1 \in \mathbb{Z} \text{, } 3(m+1)-1 \text{, } 3m+2 \in \mathbb{D}$ $f(3m+2) = \frac{4((3m+2)+1)}{3}-2$ $f(3m+2) = \frac{4(3m+3)}{3}-2$ $f(3m+2) = \frac{12m+12)}{3}-2$ $f(3m+2) = 4m+4-2$ $f(3m+2) = 4m+2$ $4m+2 \in \mathbb{C} \text{ (codomain)}$ Therefore the function is surjective.
Since the function is injective and surjective, it is a bijection.