Prim's Minimum Cost Spanning Tree (Priority Queue) Algorithm