Iterative depending depth first search

4. Iterative depending depth first search:

  • • The iterative depending algorithm is a combination of Depth-First Search (DFS) and Breadth-First-Search (BFS) algorithms. This Search algorithm finds out the best depth limit and does it by gradually increasing the limit until the goal is found.
  • • This algorithm performs Breadth-First-Search up to certain "depth limit" and keeps increasing the depth limit after each iteration until the goal node is found.
  • • The search algorithm combines the benefits of Breadth-First-Search (BFS)'s fast search and Depth-First-Search (DFS)'s memory efficiency.
  • • The Iterative search algorithm is useful uniformed search when search space is large, and depth of the goal node is unknown.

It combines the benefits of BFS and DFS search algorithm in terms of fast search and memory efficiency.


main drawback of Iterative Depending Depth First Search (IDDFS) is that it repeats all the work of previous phase.

Time complexity

Let's suppose b is the branching factor and depth is d when the worst case of time complexity is O(bd)..

Space complexity

The space complexity of IDDFS will be O(bd).


IDDFS algorithm is optimal if the path cost is a non-decreasing function of the node.

About the Author

Silan Software is one of the India's leading provider of offline & online training for Java, Python, AI (Machine Learning, Deep Learning), Data Science, Software Development & many more emerging Technologies.

We provide Academic Training || Industrial Training || Corporate Training || Internship || Java || Python || AI using Python || Data Science etc