![](https://img-blog.csdnimg.cn/20201014180756930.png?x-oss-process=image/resize,m_fixed,h_64,w_64)
图
qq_2423338532
这个作者很懒,什么都没留下…
展开
-
图的邻接表表示法
/* 图的邻接表表示法 */ #define MaxVertexNum 100 /* 最大顶点数设为100 */ typedef int Vertex; /* 用顶点下标表示顶点,为整型 */ typedef int WeightType; /* 边的权值设为整型 */ typedef char DataType; /* 顶点存储的数据类型设为字...转载 2018-11-29 18:52:42 · 141 阅读 · 0 评论 -
图的邻接矩阵
/* 图的邻接矩阵表示法 */ #include<stdio.h> #include<stdlib.h> #define MaxVertexNum 100 /* 最大顶点数设为100 */ #define INFINITY 65535 /* ∞设为双字节无符号整数的最大值65535*/ typedef int Vertex; /* 用顶点...原创 2018-12-18 11:21:52 · 186 阅读 · 0 评论 -
实验五 - 图的邻接矩阵表示法 + DFS
/* 图的邻接矩阵表示法 + DFS*/ #include<stdio.h> #include<stdlib.h> #define MaxVertexNum 10 /* 最大顶点数设为100 */ #define INFINITY 65535 /* ∞设为双字节无符号整数的最大值65535*/ typedef int Vertex; /*...原创 2018-12-18 17:30:42 · 282 阅读 · 0 评论 -
危险系数
//一次dfs就可以了,求出s到t的每一条路径,如果s到t间的某个点每次都在其中,那么这个点就是割点 //我感觉求桥也可以用map这样实现啊 #include<cstdio> #include<iostream> #include<vector> using namespace std; int n,m,way[1005],cnt[1005],s,t,ans,v...原创 2019-02-19 22:01:16 · 159 阅读 · 0 评论