Heap: 1. Converted helper functions into a full blown class. 2. Converted min-eap to be a generic heap with parametrized ordering predicate