法一:Dijkstra #include<iostream> #include<cstring> #include<algorithm> #define mm(a,x) memset(a,x,sizeof(a)) #define inf 0x3f3f3f3f const int maxn =510; using namespace std; int n,m,s,d; int map[maxn][maxn]; int dist[maxn]; int cost[maxn][maxn]; int dicost[maxn]; int path[maxn]; i...