What is the number of shortest paths from $A$ to $B$? We measure by the number of steps (not by length)
Attempt:
Notice that we should just consider 2 types of step: right and down. The longest path clearly required 8 steps. The longest 8-step path uses only short lines. Notice that if we use a long line one time, then it saves one short line (it is either right, right or down, down). Notice also if we use the hypotenuse line, then it is the same as two steps: right,down or down,right.
Now a shortest path consists only of 6 steps. These can be attained when we use 2 shortcuts: either using 2 long lines, or using 1 long line and 1 hypotenuse line.
There is only one shortest path that uses 2 long lines, the path is from $A$ to the top right, then straight to $B$.
There are only 2 shortest paths that use 1 long line and 1 hypotenuse.
So the total number of shortest paths is 3.
Are there better or simpler ways to solve the problem?


Since you knew you must take either the diagonal edge or the right most edge, you can reduce the work significantly by considering paths going only through them.
number of paths from A, distance from A