edited by
351 views
1 1 vote

Given a directed graph $G$ and an initial vertex $s$, we would like to $explore$ the graph from $s$, that is, starting from $s$ see all vertices along a path.

For example, the graph on the left side below cannot be explored from $s$ since there does not exist a path along which we can visit all vertices starting from $s$ while the graph on the right side can be explored from $s$ by following the path $s \rightarrow u \rightarrow s \rightarrow t$.

Graph image

Which of the following is TRUE?

  1. There exists a polynomial time algorithm to explore the graph from $s$.
  2. There exist s an exponential time algorithm to explore the graph from $s$ but there does not exist any polynomial time algorithm.
  3. There exists an algorithm to explore the graph from $s$ but it is not known if it runs in exponential time.
  4. The decidability of the problem is open.
  5. The halting problem of Turing machine can be reduced to checking if a graph can be explored from $s$.

1 Answer

0 0 votes

The Halting problem can be reduced…” — Whenever you see this, be suspicious.
This usually hints at undecidable problems, but reachability in graphs is decidable in P

Reachability in directed graphssolved by DFS or BFS in O(V+E)
 So the answer must be:

Checking Reachability

Always solvable in polynomial time

 

There exists a polynomial time algorithm to explore the graph from s

Answer:
Position:
Show:

Related questions

1 1 vote
0 0 answers
375
375 views
Shubham Sharma 2 asked Jun 16, 2025
375 views
Let $G=(V, E)$ be a weighted, undirected and connected graph, with weight $1 \leq$ $\mathrm{wt}_{G}(e) \leq 99$ for edge $e \in E$. Suppose $G^{\prime}$ is the graph with...
0 0 votes
0 0 answers
241
241 views
Shubham Sharma 2 asked Jun 16, 2025
241 views
Let $G$ be an undirected graph. For any pair of vertices $s, t$ in $G$, let $\operatorname{MinCut}(s, t)$ be the least number of edges that have to be deleted from $G$ so...
0 0 votes
1 1 answer
499
499 views
Shubham Sharma 2 asked Jun 16, 2025
499 views
What is the largest number of knights that can be placed on a $60 \times 60$ chessboard such that no two knights attack each other (two knights attack each other if they ...
2 2 votes
1 1 answer
493
493 views
Shubham Sharma 2 asked Jun 16, 2025
493 views
What is the solution to the following recursion?$$\begin{array}{l}T(n)=T\left(\dfrac{n}{2}\right)+T\left(\dfrac{n}{3}\right)+T\left(\dfrac{n}{6}\right)+O(n), \\T(n)=5 \qu...