摘要:
最短路 + 矩阵快速幂 我们可以改进矩阵快速幂,使得它适合本题 用图的邻接矩阵和快速幂实现 注意 dis[i][i] 不能置为 0 cpp include include include include include include using namespace std; struct edge 阅读全文
摘要:
floyd求无向图最小环 +输出路径 注意保存原来的边, 求最小环的时候要用 cpp include include include include include include include using namespace std; int n, m, dis[105][105], ans = 阅读全文