![](https://img-blog.csdnimg.cn/20201014180756916.png?x-oss-process=image/resize,m_fixed,h_64,w_64)
c
weixin_42348682
这个作者很懒,什么都没留下…
展开
-
C语言无向图的领接矩阵的创建与输出
#include <stdio.h> #define Max 20 typedef int VexType; typedef VexType Mgraph[Max][Max]; /*函数声明*/ void creat_mg(Mgraph G); void out_mg(Mgraph G); Mgraph G1; //邻接矩阵的二维数组名 int n, e; //n为顶点数,e为...原创 2018-11-27 19:26:55 · 2300 阅读 · 0 评论 -
通过创建无向图的邻接链表对无向图进行深度优先和广度优先的遍历操作
/** *说明:通过邻接链表对图进行深度优先和广度优先的遍历操作 */ # include "stdio.h" # include "stdlib.h" #define Max 20 typedef int VexType; typedef int ElemType; //邻接链表的组成 typedef struct Vnode { VexType data; struct Vnode ...原创 2018-11-28 11:05:28 · 1600 阅读 · 1 评论