Search the courses, subjects, tracks, games and features, or jump straight to a page.
2 cards from this section. Quick, good the night before a test.
What is a priority queue?
Think about how tasks are sorted in importance.
What two operations do we perform on a priority queue?
Consider what happens when a new job arrives.
What is the time complexity for inserting a job into an unsorted list?
Think about how we add jobs.
True or False: In a sorted list, the maximum element is always at the beginning.
Consider how elements are ordered.
Given a priority queue with the following tasks and their priorities: (A, 3), (B, 5), (C, 2). Insert them into a two-dimensional structure. Then, delete the max and show the state of the structure.
Remember how to determine the correct row and position for each insertion.
Critically analyze the efficiency of your two-dimensional structure for 100 jobs, state the impacts of the algorithmic complexity on performance and how it compares with heaps.
Think about the trade-offs in performance and the practical applications of each structure.
5 more questions in this section. Enroll free to practise them all.
Enroll free