The Algorithm

The solution is found using a breadth first search. Many solutions for the maze are often possible.
Not only that, but many paths may match the minimum length needed to reach the end.
Only one is displayed above.