Example: pathfinder class

Solve the shortest path problem.