copy of necessary classes
Prim's algorithm

Implementation of prim's algorithm for Minimum Spanning Tree (MST).