Number of path from $A$ to $B$ in a grid that can be traveled either rightward or upward 
In the Road map shown in the Diagram, each line segment represents a street which can only be traveled along either the rightwards or upwards direction.
Then what is the number of path from $A$ to $B$?


I have a solution which is given below in an answer, but I did not understand it, so please anyone like to explain me, Thanks.
 A: Solution Given as:: 

No. of path from $A$ to $B$ is
$(A\rightarrow B) = (A \rightarrow P \rightarrow B)+(A \rightarrow Q \rightarrow B)+(A \rightarrow R \rightarrow B)+(A \rightarrow S \rightarrow B)$
$\displaystyle  = \left(\binom{5}{1} \times 1\right)+\left(\binom{5}{2}\times \binom{5}
{4}\right)+\left(\binom{6}{5}\times \binom{4}{1}\right)+\left(1 \times 1\right)$
But I did not understand Solution, My Question is why we take points $P,Q,R$ and $S$
and How can i count no. of ways from $A$ to $B$ Through $P,Q,R$ and $S$
Thanks
A: Hint: Look at the point next to A (and call it C) and the point above A (and call it D). There is one possibility to each of the points. Then look at the point right above C. There are two possibilities to get there (by adding the number of possibilities to get to C and D). You can continue this inductively by adding the number of possibilities left of the point and under the point you are looking at.
A: 
Let the number of paths from $A$ to $B$ be $M$ and the number of paths from $C$ to $D$ be $N$.
If we subtract $N$ from $M$ we can find the number of paths wanted in the original question.
We can find M and N by repetitive permutation.
$$M=\frac{(6+3)!}{6!3!}=84$$
$$N=\frac{(3+1)!}{3!1!}=4$$
$$M-N=80$$
