A cs 542 university quiz focused on advanced data structures and algorithms, specifically prim's algorithm for minimum spanning trees and the difference between labeling and scanning and labeling methods for the shortest path problem.
Download CS 542 Quiz 1 - Advanced Data Structures and Algorithms and more Exercises Data Structures and Algorithms in PDF only on Docsity!
CS 542 – Advanced Data Structures and Algorithms
Quiz 1
Jonathan Turner 1/26/
(5 points) Suppose Prim’s algorithm for minimum spanning trees is executed on a graph with 100 vertices and 2,000 edges and that the implementation uses a d -heap. For each of the operations listed below, what is the maximum number of times that operation can be performed, based on the worst-case analysis of Prim’s algorithm?
insert
deletemin
changekey
siftup
(5 points) Explain the essential difference between the “labeling method” for the shortest path problem and the “scanning and labeling method”.