提交 67e651d9 创建 作者: 宋海霞's avatar 宋海霞

modify

上级 9da19843
...@@ -6,7 +6,7 @@ int main(int argc, char* argv[]) ...@@ -6,7 +6,7 @@ int main(int argc, char* argv[])
{ {
// //
// 初始化图(图的邻接矩阵表示法) // Initialization graph (adjacency matrix representation of graph)
// //
GraphMatrix Graph = {{ GraphMatrix Graph = {{
{ 0, 50, 10, MAX, 45, MAX}, { 0, 50, 10, MAX, 45, MAX},
...@@ -18,7 +18,7 @@ int main(int argc, char* argv[]) ...@@ -18,7 +18,7 @@ int main(int argc, char* argv[])
}}; }};
// //
// 最短路径(迪杰斯特拉算法) //Shortest path (Dijkstra algorithm)
// //
Dijkstra(&Graph); Dijkstra(&Graph);
...@@ -32,15 +32,15 @@ int main(int argc, char* argv[]) ...@@ -32,15 +32,15 @@ int main(int argc, char* argv[])
/* /*
function: function:
最短路径的迪杰斯特拉算法 Dijkstra algorithm for shortest paths
parameter: parameter:
pGraph -- 图指针 pGraph -- Figure pointer
*/ */
void Dijkstra(GraphMatrix* pGraph) void Dijkstra(GraphMatrix* pGraph)
{ {
int i; // The cursor int i; // The cursor
int mv, minw; // 存储最短路径中节点下标和长度 int mv, minw; // Stores the index and length of nodes in the shortest path
// //
// TODO: Add the code here // TODO: Add the code here
......
您添加了 0 到此讨论。请谨慎行事。
请先完成此评论的编辑!
注册 或者 后发表评论