摘要: ``` source 源端, target目的端 1.构造n*n的相邻矩阵, -1表示未相邻 int matrix[n][n] int dist[n] 初始化各节点直接到source的距离, dist[source] = 0; bool visited[n] 是否访问过 dist[source] = 阅读全文
posted @ 2023-06-11 11:27 sahara-随笔 阅读(40) 评论(0) 推荐(0)