随笔分类 - 

摘要:1 #include<stdio.h> 2 #include<stdlib.h> 3 #include "listGraph.cpp" 4 5 int main(void) { 6 listGraph G;//定义保存邻接矩阵结构的图 7 int i, j; 8 9 printf("请输入生成图的类 阅读全文

posted @ 2020-05-17 09:27 黑炽 阅读(1269) 评论(0) 推荐(0)

摘要:1 #include<stdio.h> 2 #include "matrixGraph.cpp" 3 4 int main(void) { 5 MatrixGraph G;//定义保存邻接矩阵结构的图 6 int i, j; 7 8 printf("请输入生成图的类型(0.无向图, 1.有向图):" 阅读全文

posted @ 2020-05-17 07:59 黑炽 阅读(352) 评论(0) 推荐(0)

摘要:typedef struct GNode* PtrToGNode; typedef PtrToGNode MGraph; /* 以邻接矩阵存储的图类型 */ bool Visited[MaxVertexNum]; /* 顶点的访问标记 */ struct GNode { int Nv; /* 顶点数 阅读全文

posted @ 2020-05-08 10:56 黑炽 阅读(262) 评论(0) 推荐(0)