algorithms-go/algorithms/graphs/README.md
2021-04-07 18:13:02 +08:00

30 lines
776 B
Markdown
Raw Blame History

This file contains ambiguous Unicode characters

This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.

## 图算法
### 搜索
#### 深度优先DFS(Depth First Search)
如: 树的先序遍历
思想:假设所有顶点均未被访问从一个顶点V出发依次访问它的各个邻接点直到图中所有和V相通的点都被访问到若还有未访问的顶点重复以上过程
#### 广度优先BFS(Breadth First Search)
如:树的层次遍历
思想: 从顶点V出发访问V之后依次访问v的各个未曾访问过的邻接点然后分别从这些邻接点出发依次访问它们的邻接点
队列
### 最短路径
#### 迪杰斯特拉(Dijkstra)
[详解01](http://data.biancheng.net/view/46.html)
[详解02](http://www.cnblogs.com/skywang12345/p/3711512.html)
用于有向网中计算一个节点到其他节点的最短路径