So this question told us to choose N=$\frac{1}{\epsilon}$, but how did they arrive at this N.
In the above, I know how they worked out the inequality of n>$\frac{\ln M}{\ln2}$, but I do not understand how they made the leap that if N=$\frac{\ln M}{\ln2}$+1 then n>N


With problems like this, you often start with some "scratch work" before writing up the proof. When you read the proof, it often seems that magically the correct values have been chosen, but really they are worked out ahead of time. For this problem, you know you are trying to show $\lim_{n \to \infty} a_n=1$, so you would start by looking at the difference between $a_n$ and $1$:
$$|a_n-1|=\left|\frac{n}{n+1}-1\right|=\left|\frac{n}{n+1}-\frac{n+1}{n+1}\right| = \left|-\frac{1}{n+1}\right|=\frac{1}{n+1}.$$
Now given $\epsilon>0$, the goal is to find $N \in \mathbb{N}$ such that for all $n>N$, $|a_n-1|<\epsilon$. In order to satisfy $|a_n-1|<\epsilon$, we need $\frac{1}{n+1}<\epsilon$, so $n+1>\frac{1}{\epsilon}$, or equivalently $n>\frac{1}{\epsilon}-1$. Since $\frac{1}{\epsilon}-1$ isn't an integer, we can't set $N=\frac{1}{\epsilon}-1$. Instead we need to choose an integer at least as large as $\frac{1}{\epsilon}-1$. Since $\lfloor\frac{1}{\epsilon}\rfloor \geq \frac{1}{\epsilon}-1$ and $\lfloor \frac{1}{\epsilon}\rfloor$ is an integer, setting $N=\lfloor \frac{1}{\epsilon}\rfloor$ works.
After all this "scratch work," you can go ahead and write the proof down in order. I.e., let $\epsilon >0$. Set $N=\cdots$. Then for all $n>N$, $|a_n-1|= \cdots < \epsilon$ (filling in all the details here).