keeps an algorithm to search the best path for two points (x,y) in a .txt file