.Net Implementation of a Priority Queue (aka Heap)
The code represents an F# .Net implementation of a Priority Queue; implemented using a heap data structure. Conceptually once can think of a heap as a balanced binary tree. The tree will have a root, and each node can have up to two children; a left and a right child.
I have tried using this code, and I'm finding a bug in it.
I used the PQ to program MST Prim's algorithm and after a few iterations (140), the element with the MinKey was in the middle of the Queue instead of being in front of the queue...
if anyone is looking, i can post code to GitHub
Help us improve MSDN.
Visit our UserVoice Page to submit and vote on ideas!