Tuesday, February 10, 2026
HomeData Modelling & AIAlgorithms | Graph Traversals | Question 8

Algorithms | Graph Traversals | Question 8

Given two vertices in a graph s and t, which of the two traversals (BFS and DFS) can be used to find if there is path from s to t?

(A)

Only BFS

(B)

Only DFS

(C)

Both BFS and DFS

(D)

Neither BFS nor DFS

Answer: (C)
Explanation:

We can use both traversals to find if there is a path from s to t.

Hence Option(C) is the correct answer.

Quiz of this Question
Please comment below if you find anything wrong in the above post

Whether you’re preparing for your first job interview or aiming to upskill in this ever-evolving tech landscape, neveropen Courses are your key to success. We provide top-quality content at affordable prices, all geared towards accelerating your growth in a time-bound manner. Join the millions we’ve already empowered, and we’re here to do the same for you. Don’t miss out – check it out now!
Dominic
Dominichttp://wardslaus.com
infosec,malicious & dos attacks generator, boot rom exploit philanthropist , wild hacker , game developer,
RELATED ARTICLES

3 COMMENTS

Most Popular

Dominic
32496 POSTS0 COMMENTS
Milvus
126 POSTS0 COMMENTS
Nango Kala
6869 POSTS0 COMMENTS
Nicole Veronica
11994 POSTS0 COMMENTS
Nokonwaba Nkukhwana
12090 POSTS0 COMMENTS
Shaida Kate Naidoo
7004 POSTS0 COMMENTS
Ted Musemwa
7245 POSTS0 COMMENTS
Thapelo Manthata
6956 POSTS0 COMMENTS
Umr Jansen
6944 POSTS0 COMMENTS