Completed A* Min Distance search.