Number of shortest routes Suppose you have a wire mesh which is N by M units long, made up of unit square with wire at the edges.  (So there are N+1 parallel wires all M long and, perpendicular to these, M+1 all N long).
An ant starts off at the bottom left corner of this grid (co-ordinates (0,0) and crawls on the wires the shortest possible distance to reach the top-right corner (N,M). 
How long is the shortest route.
How many different shortest routes are there? (Namely, find a formula in terms of N and M)  You might want to try this for small values of N and M and see if you can work out how the number for (N,M) relates to those for (N,M-1) and (N-1,M)
 A: HINT: Let $n_n,n_s,n_e$, and $n_w$ be the number of units that the ant crawls to the north, south, east, and west, respectively. The ant takes $n=n_n+n_s+n_e+n_w$ steps and ends up at $\langle N,M\rangle$, so $n_n-n_s=M$ and $n_e-n_w=N$. What must $n_n,n_s,n_e$, and $n_w$ be in order to minimize $n$? When you’ve done that, the spoiler-protected block below contains a hint for counting the shortest paths.

 Once you know that $n_e=N$ and $n_n=M$, observe that you can mix the $N$ eastward and $M$ northward segments in any order. Moreover, once you know which $N$ of them are to the east, you know the whole route: the other $M$ must be to the north. How many ways are there to select $N$ of the segments to be to the east?

A: @Brian M. Scott Hey, could you explain more into what you mean by : "Moreover, once you know which N of them are to the east, you know the whole route: the other M must be to the north. How many ways are there to select N of the segments to be to the east?"
perhaps, an example? if that is possible?
THanks
