Algorithm: MCQ Set – 08

Q71: Consider the Array: 26, 35, 1, 49, 54, 30, 99. How array will look like after 2 (two) iterations of Bubble Sort?

  • (A) 26, 1, 35, 49, 54, 30, 99
  • (B) 26, 1, 35, 49, 30, 54, 99
  • (C) 1, 26, 35, 30, 49, 54, 99
  • (D) None of these

Q72: The running time of an algorithm is given by T(n) = T(n – 1) + T(n – 2) – T(n – 3), if n > 3, and n, otherwise.

  • (A) n
  • (B) log n
  • (C) nn
  • (D) n2

Q73: Time Complexity of Tower of Hanoi Problem (Recursive) with n disks is

  • (A) n2
  • (B) 2n
  • (C) 3n
  • (D) n3

Q74: NP Problem is

  • (A) Polynomial Problem
  • (B) Non Deterministic Polynomial Problem
  • (C) Easy to Solve problem
  • (D) All of Above

Q75: Worst case Time Complexity of Multiplication of  two n X n Matrix  is

  • (A) n2
  • (B) n2log(n)
  • (C) n log(n)
  • (D) n3

Q76: Consider the Array: 26, 35, 11, 49, 54, 30, 80. How array will look like after 2 (two) iterations of Bubble Sort?

  • (A) 26, 11, 35, 49, 54, 30, 80
  • (B) 26, 11, 35, 49, 30, 54, 80
  • (C) 11, 26, 35, 30, 49, 54, 80
  • (D) None of these

Q77: f(n) = θ (g(n) ) implies

  • (A) f(n) = O (g(n) ) only
  • (B) f(n) = Ω (g(n) ) only
  • (C) f(n) = O (g(n) ) and f(n) = Ω (g(n) )
  • (D) None of these

Q78: Infinite recursion leads to

  • (A) Overflow of run-time stack
  • (B) Underflow of registers usage
  • (C) Overflow of I/O cycles
  • (D) Underflow of run-time stack

Q79: The time required to find shortest path in a graph with n vertices and e edges is

  • (A) O(e)
  • (B) O(n)
  • (C) O(e2)
  • (D) O(n2)

Q80: For NP-Complete problem

  • (A) Several Polynomial time algorithms are available.
  • (B) Polynomial Time algorithms are not exist, hence can not be discovered
  • (C) No Polynomial Time algorithm is discovered yet
  • (D) None of Above

Answer:

QuestionQ71Q72Q73Q74Q75Q76Q77Q78Q79Q80
AnswerCABBDBCADC

≪ Previous | Next ≫