Question d’entretien chez Amazon

For any problem how to decide which algorithm to use from BFS and DFS?