Reputation: 11
I was doing interview question on priority queues and have a simple question I was hoping to get some help with. The question is:
Should the priorities be integral? Could I implement string priorities.
Thanks in advance :-)
Upvotes: 0
Views: 575
Reputation: 25522
?
The priorities can be anything that have a partial order defined, although a total order would be more common (e.g. integers, or strings ordered lexiographically).
Upvotes: 1