Asked in Computer ProgrammingMath and ArithmeticC Programming
How does Prim's algorithm work?
August 24, 2008 11:56AM
First a vertex is selected arbitrarily. on each iteration we expand the tree by simply attaching to it the nearest vertex not in the tree. the algorithm stops after all yhe graph vertices have been included.. one main criteria is the tree should not be cyclic.