Hi, please, I want the shortest path algorithm using arrays (Data structure) and the path passing through all the points once and return back to the initial point. ex:
0-1-4-2-3-5-0 (path cost=10)
0-3-2-5-4-1-0 (path cost=15)

so 0-1-4-2-3-5-0 is the correct answer.

Recommended Answers

Did you ask google?

Jump to Post

All 2 Replies

Did you ask google?

yes but I get dijkstra's algorithm, and dijkstra get the shortest path but not passing through all the points..

Be a part of the DaniWeb community

We're a friendly, industry-focused community of 1.20 million developers, IT pros, digital marketers, and technology enthusiasts learning and sharing knowledge.