- DSA Problems
Minimum Number of Vertices to Reach All Nodes
Find the minimum set of vertices needed to reach all nodes in a directed acyclic graph using topological sorting and in-degree analysis.
- DSA Problems
Flood Fill Algorithm Implementation and Analysis
Complete Java solution for flood fill algorithm with BFS/DFS approaches, time complexity analysis, and practical implementation considerations for FAANG interviews.
- DSA Problems
Max Area of Island Java Solution
Complete Java implementation for finding maximum area of island in 2D grid using DFS and BFS approaches with time and space complexity analysis.
- DSA Problems
Pacific Atlantic Water Flow Problem Solution
Complete Java implementation for finding cells where water can flow to both Pacific and Atlantic oceans in a grid.
- DSA Problems
Clone Graph Problem Solution | Graph Traversal and Deep Copy
Complete Java solution for cloning a connected undirected graph with BFS/DFS approaches, handling node duplication and adjacency mapping.
- DSA Problems
Number of Islands Problem Solution
Complete Java implementation for counting connected land cells in a 2D grid using DFS and BFS approaches.
- DSA Problems
Word Search II Java Solution with Trie and DFS
Complete Java implementation for Word Search II problem using Trie data structure and depth-first search with backtracking.
- DSA Problems
Lowest Common Ancestor of a BST
Find the lowest common ancestor in a binary search tree using iterative and recursive approaches with O(log n) time complexity.
- DSA Patterns
Connected Components in Graphs and Grids
Complete guide to finding connected components using Union-Find, DFS, and BFS approaches with Java implementations for FAANG interviews.
- DSA Patterns
Cycle Detection in Directed Graphs Using DFS
Complete Java solution for detecting cycles in directed graphs with time complexity analysis and implementation trade-offs.
- DSA Patterns
Topological Sort Algorithm Implementation and Applications
Complete Java solution for topological sorting with DFS and BFS approaches, including cycle detection and practical use cases.
- DSA Problems
Subtree of Another Tree Java Solution
Complete Java implementation for checking if one binary tree is a subtree of another, including multiple approaches and time complexity analysis.
#DFS
Browse articles tagged with #DFS