I am studying graph currently. I found a question, which asks forThe List A[] which shows shortest distances between $V$ and everyother vertexThe List B[] which shows shortest paths between $V$ and every other vertex as subpoints. I don't think the question wants me to compute the same values twice, but I don't know what the difference between shortest distance and shortest path is. Can anyody explain?
What is the difference between shortest distance and shortest path?
terminology;graphs
As @randomA already indicated in a comment, a shortest path from $v$ to $w$ is a sequence of vertices (that describes a path from $v$ to $w$, which is shortest among such sequences).The shortest distance on the other hand is the length of a shortest path, i.e. a number.As a sidenote, be aware that there can be multiple shortest paths (but only one shortest distance). Thus, you might want to check, if the the question requires you to find one or all of them.