Topological Sort - Find Eventual Safe States
Consider two approaches to find eventual safe states: (1) DFS with memoization and (2) reverse graph + Kahn's algorithm. When is the DFS with memoization approach preferable over the Kahn's algorithm approach?
