1answer.
Ask question
Login Signup
Ask question
All categories
  • English
  • Mathematics
  • Social Studies
  • Business
  • History
  • Health
  • Geography
  • Biology
  • Physics
  • Chemistry
  • Computers and Technology
  • Arts
  • World Languages
  • Spanish
  • French
  • German
  • Advanced Placement (AP)
  • SAT
  • Medicine
  • Law
  • Engineering
Readme [11.4K]
3 years ago
11

A computing company is running a set of processes every day. Each process has its own start time and finish time, during which i

t runs continuously. The company has developed a process_check module, that runs briefly (consider this to take just 1 point in time) and records important pieces of information about the processes running at that time. The company would like to run the process_check module as few times as possible each day, while making sure that the module is called at least once during the execution of each process.
Required:

Give an efficient algorithm that based on the start and finish time of each process will find the smallest set of possible moments of time at which to run the process_check module (making sure that the module is invoked at least once for each process).
Computers and Technology
1 answer:
Helga [31]3 years ago
5 0

Answer:

Above all else, let us show that this issue has the greedy choice property.

This implies that worldwide ideal arrangement can be gotten by choosing local ideal arrangements. Presently notice the following:

The global optimal solution of the issue requests us to track down the minimum number of times process_check module should be run.

It is likewise referenced that during each running interaction, process_check module should be called atleast once. Along these lines, the minimum possible number of process_check calls happens when process_check is made close to the quantity of the processes that are run.

Along these lines, we see that the global optimal solution is shaped by choosing optimal answer for the nearby advances.

Along these lines, the issue shows greedy choice property. Thus, we can utilize a greedy algorithm for this issue.

The greedy step in this calculation is to postpone the process_check as far as might be feasible. Thus, it should be run towards the finish of each interaction. So the following algorithm can be utilized:

Sort the cycles by utilizing the completion times.

Towards the finish of the 1st process in the arranged list, run the process_check module. Right now any process that is now running is removed the arranged rundown. The main interaction is additionally removed from the sorted list.

Now repeat stage 2, till all processes are finished.

In the above mentioned algorithm, the costliest advance is the step of sorting. By utilizing the optimal sorting algorithm, for example, merge sort, we can achieve it in O(n log n) asymptotic time.

Along these lines, this greedy algorithm additionally takes O(n log n) asymptotic time complexity.

You might be interested in
ATM is an abbreviation that stands for Automatic Teller machine?
vova2212 [387]

Answer:

ATM means "At The Moment" or "Automated Teller Machine (cash machine)" So now you know - ATM means "At The Moment" or "Automated Teller Machine (cash machine)" - don't thank us. YW! What does ATM mean? ATM is an acronym, abbreviation or slang word that is explained above where the ATM definition is given.

Explanation:

3 0
3 years ago
Read 2 more answers
Who is he can anyone help me​
34kurt
This person is Elon Musk, the owner of Tesla :)
5 0
2 years ago
Read 2 more answers
Why might you use the "search network campaigns with display opt-in" campaign type?
slava [35]
The answer is:
You can use one budget to advertise on the Search Network and Display Network
5 0
3 years ago
Read 2 more answers
What is output if the user enters -5?
7nadin3 [17]

Answer:

The left

Explanation:

6 0
2 years ago
Read 2 more answers
how much should an organization consider moving into the cloud before full outsourcing starts making more business sense
PIT_PIT [208]

Answer:

47

Explanation:

capital steez

8 0
3 years ago
Read 2 more answers
Other questions:
  • 3k means about 3 thousand bytes. how would you express two hundred million bytes?
    8·1 answer
  • How is the Task Manager helpful in displaying which resources your computer is using and how fast?
    5·2 answers
  • What is the maximum amount that OSHA can impose as a penalty on an employer for each Willful violation?
    11·1 answer
  • You maintain an RODC running Windows Server 2012 R2 at a branch office, and you want Juanita, who has solid computer knowledge,
    13·1 answer
  • Does the game cooking fever use data?
    10·1 answer
  • What is a file type and why is it important? Give at least three examples of file
    7·1 answer
  • question i need a real answer cuase i have a virus cuase off my borther and these are the notifacations i get and now these site
    11·1 answer
  • Consumer consequences for illegally downloading software
    6·1 answer
  • Display all the lines in unixPasswd that contain at least 10 consecutive lowercase letters. How many names are there in total th
    12·1 answer
  • Rita tried unsuccessfully to open a PDF file attachment in her Inbox by double-clicking the attachment in the Reading Pane. What
    8·1 answer
Add answer
Login
Not registered? Fast signup
Signup
Login Signup
Ask question!