Codeforces and Polygon may be unavailable from May 23, 4:00 (UTC) to May 23, 8:00 (UTC) due to technical maintenance. ×

Tatsugiri's blog

By Tatsugiri, history, 4 weeks ago, In English

Given an undirected graph with positive cost number on each edge, I need to calculate shortest path from p1 to pn node visiting a certain node pk(pk is not a start or end node).

The main problem is in restriction that the solution path should not visit any node more than once. Because of that, there may be no solution at all.

Is there any polynomial-time algorithm to solve the problem, or can it be proven np-hard?

Full text and comments »

  • Vote: I like it
  • +18
  • Vote: I do not like it