Refactoring
Allow the priority queue size to be smaller than if the maximum number
of occurrences is smaller