DFS and BFS in graphs

Are the DFS and BFS traversals unique for a given graph. I think they are not, want to confirm with you.

No, traversal depends on which child you choose for particular node so they are not unique.
It is unique only when every node has less than 2 child

Thank you :slight_smile:

code not being submitted

https://practice.geeksforgeeks.org/problems/flood-fill-algorithm1856/1/?category[]=Matrix&category[]=Matrix&problemStatus=unsolved&page=2&query=category[]MatrixproblemStatusunsolvedpage2category[]Matrix# https://ide.codingblocks.com/s/571620

please create new doubt request with question reference.TAs will answer it.

Thanks :slight_smile:

I hope I’ve cleared your doubt. I ask you to please rate your experience here
Your feedback is very important. It helps us improve our platform and hence provide you
the learning experience you deserve.

On the off chance, you still have some questions or not find the answers satisfactory, you may reopen
the doubt.