update the Dijkstra Algorithm and add the Shortest Path Fast Algorithm (SPFA)