Question: 3) A heap is being stored in an array. A heap may be a minimum heap or a maximum heap. Which would you use to

3) A heap is being stored in an array. A heap may be a minimum heap or a maximum heap. Which would you use to implement a non-increasing [in-place] sort? 4) Situation: The order in which patients at a certain emergency room are seen by the doctor is based on arrival time minus 10 minutes for each major wound, minus 5 minutes for each minor wound, and plus 3 minutes for each time the patient annoys the nurse. You can assume a maximum wait time of 2 days. If a priority queue is used in the software at the nurses' station, would you use a minimum heap or a maximum heap to implement the priority queue? Thought-provoker: Do you think if you annoyed the nurse enough, s/he would smack you around enough for you to move to the head of the line?) 5) A heap data structure: A) always has the maximum key value in the root of the tree B) could really use a maid every other Thursday C) is always stored in an array D) must be a full tree E) needs parent pointers if not stored in an array
Step by Step Solution
There are 3 Steps involved in it
Get step-by-step solutions from verified subject matter experts
