How to find path from src to dest using this can you make required changes in the code for the input i have given

hello @kishoretaru
just pass an extra vector to ur dfs function.
inserted ur current node in the vector and call dfs to its neighbours
and when u hit ur base case ie src==dest then simply print all the nodes that are there in the vector that will tell u the order nodes from src to destinations

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.

Pls share the code of how to find path from src to dest if exists in ide

have u tried that i suggested u before

Yes , once send code for above approach I’m not able to figure it out

@kishoretaru
check this->

approach->

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.