Hi, my problem is that I can't for the life of me wrap my head around how to implement priority in my circular queue. Here's what I've got thus far: Also my problem only lies in my insert() where the prioritizing needs to take place. I'm reading from a file as well so if needed, probably not though, I can post ...
I'm in the process of working on a lab and have hit a wall and can't quite figure out what's going on with this. The requirements are that I have a circular queue with one external pointer to track the rear of it. It seems to enque fine, however I keep getting null pointer exceptions when I deque and I'm not ...
Looks like you have missed a step. You need to make rear.link point to the new node as well. But do it on the correct order otherwise you will stuff the queue. If all else fails write several nodes down on a piece of paper and work out what needs to happen and in what order, when you add a new ...