I am working on a program in which a priority queue extends a queue; class PQueue: public Queue My Pqueue list is enqueued using Queue's enqueue method, but I created a dequeue method for Pqueue to remove items with minimum priority. Somehow i can't implement it.
If you have a pQueue like head[2 8 5 9 0 3 9 7]tail, The list would become 2 8 5 9 3 9 7, the 0 removed and stored in a variable for return. Pls help
Aucun commentaire:
Enregistrer un commentaire