Graph Theory37 sections · 1633 units
Open in CourseQuiz: Counting Paths
Knowledge check
Check Your Understanding
Investigation: Count shortest paths from to all nodes. When relaxing edge , you find dist[u] + w = dist[v]. What do you do with the path count?
- A.Set
count[v] = count[u] - B.Add
count[u]tocount[v] - C.Set
count[v] = count[u] + 1 - D.Do nothing, distance didn't improve