Wednesday, October 9, 2019

CS2040s: Discussion Group 8

RECAP

BFS - Find neighbours first
DFS - Go as far as possible (Stack)

Kahn's algorithm
1. Keep removing each time we go down the list
2. After each removal, append to the list
3. Final result topological

But the sort is not unique

No comments:

Post a Comment