How To Prove it: 7.1.6 Definition 7.1.1. Suppose $A$ and $B$ are sets. We’ll say that $A$ is equinumerous with $B$ if there is a function $f : A → B$ that is one-to-one and onto. We’ll write $A ∼ B$ to indicate that $A$ is equinumerous with $B$. For each natural number $n$, let $I_{n}$ = { $i ∈ Z^+ | i ≤ n$ }. A set $A$ is called finite if there is a natural number $n$ such that $I_{n} ∼ A$. Otherwise, A is infinite.
Question 7.1.6: Prove that for all natural numbers $n$ and $m$, if $I_{n}$ ∼ $I_{m} $ then $n$ = $m$. (Hint: Use induction on n.)
My Attempt: Suppose $I_{n}$ ∼ $I_{m}$ where $ n \in \Bbb N$, $m \in \Bbb N $ are both arbitrary, then we can choose a function $f : I_{n} → I_{m}$ that is one-to-one and onto. Since $f$ is one-to-one there must the same number of elements in $I_{m}$ as in $I_{n}$ or we can say $m = n$. Then we can conclude that if $I_{n}$ ∼ $I_{m}$ then $n = m$.
I am assuming that its wrong because the book suggests to used induction but I can't see why it is so. What am I missing?
Also is it ok to write $n, m \in \Bbb N $ instead of $ n \in \Bbb N$, $m \in \Bbb N $.
 A: One problem with your proof is in the line: 

Since $f$ is one-to-one there must be the same number of elements in
  $I_m$ as in $I_n$.

This is not a true fact! For instance, I can define a function $f:\{1\}\rightarrow\{1, 2\}$ with $f(1)=1$. It is 1-1, but the sets are not equinumerous. Of course, my $f$ is not onto; this is why you need both. Incidentally, 1-1 is sometimes called "injective" and onto is sometimes called "surjective"; a function that is both is called "bijective".
Perhaps a larger problem is that you haven't actually used the properties of $f$. You can't just say "because $f$ is bijective, $m=n$", because that's what you need to prove. So suppose you have $I_n\sim I_m \Rightarrow n = m$, and a bijection between them. Now consider $I_{n+1}$ and $I_{m+1}$. Can you find a bijection between them based on the one you had for $I_n$ and $I_m$? That's the induction.
Lastly, yes, it's ok to say $\forall m,n \in \Bbb{N}$. Actually it's not ok to say, $\{\forall i \in Z^+ \mid i \leq n\}$, as you did. The $\forall$ is extraneous. Correct would be: $\{ i \in \Bbb{Z}^+ \mid i \leq n \}$, pronounced "the set of $i$ in $\Bbb{Z}^+$ such that $i \leq n$".
