plan change: create a priority queue using a min-heap instead of a raw heap