Question: Consider the following longest (st)-path problem: given an undirected graph G, an integer k, and two distinct vertices s and t, your goal is to
Consider the following longest (st)-path problem: given an undirected graph G, an integer k, and two distinct vertices s and t, your goal is to nd if there's a simple path using k or more edges from s to t. Prove that, unlike the problem of nding the shortest path in a graph, the longest (st)-path problem is NP-complete (which involves first showing that it's NP and then that it's NP-hard).
Step by Step Solution
There are 3 Steps involved in it
Get step-by-step solutions from verified subject matter experts
