Graphs
Ways to traverse a graph:
- Pre-order
- In-order
- Post-order
- Reverse post-order (RPO) – if there is a path from A to B, A appears before B
RPO of a DAG is also called topological sort. It is undefined in case if there is a cycle. Then a graph can be partitioned in Strongly Connected Components (SCC).