Head First in Graph

图论第一课

In mathematics and computer science, graph theory is the study of graphs, which are mathematical structures used to model pairwise relations between objects. A graph in this context is made up of vertices (also called nodes or points) which are connected by edges (also called arcs, links, or lines). A distinction is made between undirected graphs, where edges link two vertices symmetrically, and directed graphs, where edges link two vertices asymmetrically. Graphs are one of the principal objects of study in discrete mathematics.

我们会讲哪些东西

图的表示

深度优先遍历

广度优先遍历

环检测,floodfill

最小生成树

最短路径

Pictures in ECAD https://www.jlc-ecad.com/editor#j|0362225508914382819bece9e4497ee4|

Graph problems in leetcode

https://leetcode.com/problems/is-graph-bipartite

https://leetcode.com/problems/max-area-of-island