search - Find the shortest path between two vertices a and b in a specified graph. Graph's properties are in the description. -


properties of graph:

  • graph has v vertices , e edges.

  • it connected, undirected , positive weighted.

  • graph has 1 cycle.

the goal find shortest path between 2 vertices , b in o(v) time.

a link similar question if there's 1 appreciated.

consider using breadth-first search, o(v+e)

https://en.wikipedia.org/wiki/breadth-first_search


Comments

Popular posts from this blog

Command prompt result in label. Python 2.7 -

javascript - How do I use URL parameters to change link href on page? -

amazon web services - AWS Route53 Trying To Get Site To Resolve To www -