
树、图
柠檬超级酸
What Ever
展开
专栏收录文章
- 默认排序
- 最新发布
- 最早发布
- 最多阅读
- 最少阅读
-
图的基本操作
图的邻接矩阵存储 #define MaxVertexNum 100;//顶点数目的最大值 typedef char VettexType;//顶点的数据类型 typedef int EdgeType;//权值的数据类型(表示边) typedef struct{ VextexType vex[MaxVertexNum];顶点表 EdgeType edge[MaxVertexNum][MaxV...原创 2019-12-04 21:14:11 · 363 阅读 · 0 评论 -
树的基础算法
二叉树的存储结构 链式存储结构 typedef struct{ ElemType data; struct BiTNode *lchild, *rchild; }BiTNode, *BiTree; 先序遍历 递归算法 void PreOrder(BiTree T){ if(T!=NULL){ visit (T); PreOrder(T->lchild); PreOr...原创 2019-12-04 16:38:49 · 597 阅读 · 0 评论