Data Structures | Graph | Question 9

Last Updated :
Discuss
Comments

In which scenario would a directed acyclic graph (DAG) be most suitable?

Representing dependencies between tasks in a project schedule

Modeling a social network with friend connections

Finding the shortest path between two nodes in a weighted graph

Performing breadth-first search (BFS) on a graph

Share your thoughts in the comments