Exam 8: Queues

arrow
  • Select Tags
search iconSearch Question
flashcardsStudy Flashcards
  • Select Tags

When using a circular array implementation for a queue, when either pointer is about to run off the end of the array, that pointer is reset to -1.

Free
(True/False)
4.7/5
(30)
Correct Answer:
Verified

False

When using a circular array implementation for a queue, during the add operation, the front pointer moves ahead of the rear pointer.

Free
(True/False)
4.9/5
(33)
Correct Answer:
Verified

False

When items are added to a priority queue, they are assigned an order of rank.

Free
(True/False)
4.7/5
(45)
Correct Answer:
Verified

True

What can you do if items in a priority queue cannot use the comparison operators?

(Multiple Choice)
4.8/5
(42)

In a priority queue, items waiting in the queue the longest are always popped next.

(True/False)
4.9/5
(27)

The ready queue contains processes waiting to use the CPU.

(True/False)
4.8/5
(31)

A checkout line at a grocery store is an example of a queue.

(True/False)
5.0/5
(32)

An example of a computer simulation that can use queues is traffic flow on a busy highway.

(True/False)
4.7/5
(42)

In computer science, process scheduling can be handled by simple or priority queues.

(True/False)
4.8/5
(35)

In the array implementation of a queue, the pop operation is most efficient if the front of the queue is fixed at index position 0.

(True/False)
4.9/5
(32)

In the supermarket simulation, which of the following would be a property of a Cashier object?

(Multiple Choice)
4.9/5
(43)

Which of the following is NOT true of a priority queue?

(Multiple Choice)
4.9/5
(36)

In a priority queue, what does the add method do when handling a new item and the new item is greater than or equal to the item at the rear?

(Multiple Choice)
4.7/5
(32)

When items are removed from a priority queue, items of lower priority are removed before those of higher priority.

(True/False)
4.9/5
(34)

Which of the following is true about a standard queue?

(Multiple Choice)
4.8/5
(38)

The add operation for a queue adds a node at the head of the structure.

(True/False)
4.9/5
(35)

Which of the following is NOT true of a priority queue?

(Multiple Choice)
4.8/5
(38)

Simulation programs can use a range of integer values to mimic variability in the simulation.

(True/False)
4.9/5
(34)

What must occur when a wrapped item is accessed with the peek or pop method in a priority queue?

(Multiple Choice)
4.8/5
(36)

In a linked implementation of a queue, what does the add operation do?

(Multiple Choice)
4.9/5
(38)
Showing 1 - 20 of 50
close modal

Filters

  • Essay(0)
  • Multiple Choice(0)
  • Short Answer(0)
  • True False(0)
  • Matching(0)