second an third Algos, dijkstra + A*