摘要:
单源最短路径算法 #include<iostream> using namespace std; int map[50][50]; int book[50]; int n,m,min1,u; int dis[50]; int main(){ cin>>n>>m; for(int i=1;i<=n;i 阅读全文
摘要:
图的邻接矩阵和图 图就是N个顶点和 M条边组成的集合 用二维数组存储图的邻接矩阵用dfs去遍历图 #include<iostream> using namespace std; int map[50][50]; int book[50]; int n,m,sum,sp; bool f; void d 阅读全文