PRACTICE

DFS Interview Questions

24 DFS problems asked across FAANG and top tech companies. Approach hints, optimal solutions, and related problems.

🔒

to save your progress.

0ProblemDifficultyCompaniesBreakdown / SolutionLeetCode
Number of IslandsMedium5 companiesView breakdown →
Course Schedule IIMedium5 companiesView breakdown →
Course ScheduleMedium4 companiesView breakdown →
Validate Binary Search TreeMedium7 companiesView breakdown →
Maximum Depth of Binary TreeEasy7 companiesView breakdown →
Invert Binary TreeEasy5 companiesView breakdown →
Same TreeEasy6 companiesView breakdown →
Symmetric TreeEasy5 companiesView breakdown →
Design Add and Search Words Data StructureMedium5 companiesView breakdown →
Alien DictionaryHard6 companiesView breakdown →
Kth Smallest Element in a BSTMedium6 companiesView breakdown →
Lowest Common Ancestor of a Binary TreeMedium8 companiesView breakdown →
Clone GraphMedium5 companiesView breakdown →
Serialize and Deserialize Binary TreeHard8 companiesView breakdown →
Flatten Nested List IteratorMedium3 companiesView breakdown →
Word SearchMedium4 companiesView breakdown →
Evaluate DivisionMedium2 companiesView breakdown →
Minimum Edge Reversals So Every Node Is ReachableHard3 companiesView breakdown →
Accounts MergeMedium2 companiesView breakdown →
Binary Tree Maximum Path SumHard3 companiesView breakdown →
Lowest Common Ancestor of a Binary Search TreeMedium1 companiesView breakdown →
Flatten a Multilevel Doubly Linked ListMedium1 companiesView breakdown →
Minimum Fuel Cost to Report to the CapitalMedium1 companiesView breakdown →
Web Crawler MultithreadedMedium1 companiesView breakdown →

Practice with a Mock Interview

Solve these DFS problems under real interview pressure with our AI interviewer.

Start Mock Interview →