xxunknown321 0 Newbie Poster

First off let me just say i don't want anyone to do my homework for me. I get a greater sense of satisfaction knowing that I did the work. with that being said I'm looking for some way to start or some input on what measures I should take while doing my assignment. Thank you in advance.


our assignment is to write a C/C++ program that can handle jobs in a long-term queue of an operating system based on priorities. The functions of the program must include:

A random number generator that can generate numbers between 1 and 100. A number generated by the generator would be a priority of a job and will be put in the queue after it has been generated.

A priority queue with size ten to handle the priority mechanism. The highest priority job will be print out first. The info to print out is the random number that represents the priority of the job.

At first you should let your program generates at least 10 random numbers, and put these numbers in the priority queue. Thereafter, the priority queue starts to dispatch the highest priority number while the random number generator continues generating numbers. Note that the lower number has higher priority. Every time the highest priority number has been dispatched and a random number is generated your must print out these number along with the numbers in the queue. You deem that the highest priority number dispatching and the random number generating are happening at the same time. Your output should look somewhat like Figure 1 in the attachment above the submission window.

Note that putting numbers in a sorted list as a queue is not acceptable because it is not efficient. You must implement the priority queue data structure in your assignment.


PLEASE RESPOND AT EARLIEST CONVENIENCE! THANK YOU!

Be a part of the DaniWeb community

We're a friendly, industry-focused community of developers, IT pros, digital marketers, and technology enthusiasts meeting, networking, learning, and sharing knowledge.