Programming and Data Structures - Queues

1. Which of the following is a collection of items into which items can be inserted arbitrarity and from which only the smallest item can be removed?

Cancel reply

Your email address will not be published. Required fields are marked *


Cancel reply

Your email address will not be published. Required fields are marked *


2. A________search begins the search with the element that is located in the middle of the array.

  • Option : D
  • Explanation : Binary Search algorithm can do this because it firstly searches the middle element. If the required element is less than the middle one, then search the middle element in the less than a part. If the required element is greater than the middle one, then search in the greater part. So the answer is 'D'.
Cancel reply

Your email address will not be published. Required fields are marked *


Cancel reply

Your email address will not be published. Required fields are marked *


3. A priority queue is used to implement a stack S that stores characters PUSH(C)is implemented as INSERT(Q,C,K)where K is an appropriate integer key chosen by the implementation.POP is implemented as DELETEMIN(Q).For a sequence of operations,the key chosen are in

Cancel reply

Your email address will not be published. Required fields are marked *


Cancel reply

Your email address will not be published. Required fields are marked *


4. Queues serve major role in

Cancel reply

Your email address will not be published. Required fields are marked *


Cancel reply

Your email address will not be published. Required fields are marked *


5. Which of the following data structure may give overflow error, even though the current number of elements in it is less than its size?

Cancel reply

Your email address will not be published. Required fields are marked *


Cancel reply

Your email address will not be published. Required fields are marked *