Google Interview Question

DFS, BFS, recursion, big-o notation