1. Question: Suppose we have a circular array implementation of a queue, with ten items in the queue stored at data[2] through data[11]. The CAPACITY is 42. Where does the push member function place the new entry in the array?

    A
    data[1]

    B
    data[2]

    C
    data[11]

    D
    data[12]

    Note: Not available
    1. Report
  2. Question: The operation for adding an entry to a stack is traditionally called ________.

    A
    add

    B
    append

    C
    insert

    D
    push

    Note: Not available
    1. Report
  3. Question: For a complete binary tree with depth d, the total number of nodes is:

    A
    2d+1

    B
    2d

    C
    2d-1

    D
    2d2

    Note: Not available
    1. Report
  4. Question: Which of the following sorting algorithms yield approximately the same worst-case and average-case running time behavior in O(n*log(n))?

    A
    Bubble sort and selection sort

    B
    Heap sort and merge sort

    C
    Quick sort and radix sort

    D
    Tree sort and Median-of-3 quicksort

    Note: Not available
    1. Report
  5. Question: Which of the following is false?

    A
    A binary search begins with the middle element in the array

    B
    A binary search continues halving the array either until a match is found or until there are no more elements to search

    C
    If the search argument is greater than the value located in the middle of the binary, the binary search continues in the lower half of the array

    Note: Not available
    1. Report
  6. Question: Which of the following applications may use a stack?

    A
    A parentheses balancing program

    B
    Keeping track of local variables at run time

    C
    Syntax analyzer for a compiler

    D
    All of the above

    Note: Not available
    1. Report
  7. Question: What is the value of the post-fix expression 6 3 2 4 + - *?

    A
    Something between -15 and -100

    B
    Something between -5 and -15

    C
    Something between 5 and 15

    D
    Something between 15 and 100

    Note: Not available
    1. Report
  8. Question: The minimum number of interchanges needed to convert the array 89,19,14,40,17,12,10,2,5,7,11,6,9,70 into a heap with the maximum element at the root is:

    A
    0

    B
    1

    C
    2

    D
    3

    Note: Not available
    1. Report
  9. Question: Suppose T is a complete binary tree with 14 nodes. What would be the minimum possible depth of T?

    A
    0

    B
    3

    C
    4

    D
    5

    Note: Not available
    1. Report
  10. Question: In which data structure do the insertion and deletion take place at the same end?

    A
    Linked list

    B
    Tree

    C
    Stack

    D
    Linked list of stack

    Note: Not available
    1. Report
Copyright © 2025. Powered by Intellect Software Ltd