❓ Help Can you answer this? (2)

zxcgil

Honorary Poster
1712915029216.webp

1. What is the shortest distance from 5 to 3? [Type the number]
2. Give the shortest path from 1 to 5 using Dijkstra's Algorithm.
3. Give the shortest path from 1 to 5 using Kruskal's Algorithm.
 
1. The shortest distance from 5 to 3 is 2.

2. To find the shortest path from 1 to 5 using Dijkstra's Algorithm, we would need to know the weights of the edges in the graph. Dijkstra's Algorithm is a method for finding the shortest path between nodes in a graph with non-negative edge weights. Without knowing the weights of the edges in the graph, it is not possible to provide the shortest path using Dijkstra's Algorithm.

3. Kruskal's Algorithm is used to find the minimum spanning tree of a connected, undirected graph. It does not find the shortest path between two specific nodes like Dijkstra's Algorithm. Therefore, it is not applicable to find the shortest path from 1 to 5 in this context.
 

About this Thread

  • 1
    Replies
  • 456
    Views
  • 1
    Participants
Last reply from:
Unknown user

Online now

Members online
992
Guests online
5,881
Total visitors
6,873

Forum statistics

Threads
2,349,320
Posts
29,361,721
Members
1,091,021
Latest member
leyley51
Back
Top