Algorithm: MCQ Set – 03

Q21: Best case time complexity of heap sort technique is

  • (A) Stable
  • (B) O(n2)
  • (C) O(nlog2n)
  • (D) O(log2n)

Q22: The Average case occur in linear search algorithm

  • (A) When Item is somewhere in the middle of the array
  • (B) When Item is not in the array at all
  • (C) When Item is the last element in the array
  • (D) When Item is the last element in the array or is not there at all

Q23: In the worst case, the number of comparisons needed to search a single linked list of length n for a given element is

  • (A) log(n)
  • (B) n/2
  • (C) log(n/2)-1
  • (D) n

Q24: N-Queens Problem can be solved easily by

  • (A) Dynamic Programming
  • (B) Backtracking Method
  • (C) Greedy Method
  • (D) Divide and Conquer Method.

Q25: Worst case Time Complexity of Linear Search is

  • (A) O(n)
  • (B) O(log(n))
  • (C) O(1)
  • (D) O(nlog(n))

Q26: Worst case Time Complexity of Heap Sort Algorithm  is

  • (A) O(log(n))2
  • (B) O(n)
  • (C) O(n2)
  • (D) O(nlog(n))

Q27: Analyzing of an algorithm involves

  • (A) Evaluating the complexity only
  • (B) Validating the algorithm Only
  • (C) Both Validating the algorithm and Evaluating the Complexity
  • (D) None of these

Q28: Which of the following data structure may be used to aid implementation of radix sort?

  • (A) Stack
  • (B) Heap
  • (C) Binary Search Tree
  • (D) Queue

Q29: Which of the following sorting methods would be most suitable for sorting a list which is almost sorted

  • (A) Bubble Sort
  • (B) Selection Sort
  • (C) Quick Sort
  • (D) Merge Sort

Q30: Breadth First Traversal (BFS) is a method to traverse

  • (A) Graph using shortest path
  • (B) All successors of a visited node before any successors of any of those successors
  • (C) A single path of the graph as far as it can go
  • (D) None of these

Answer:

QuestionQ21Q22Q23Q24Q25Q26Q27Q28Q29Q30
AnswerCADBADCDAB

≪ Previous | Next ≫


Leave a Reply

Your email address will not be published.