PA of Algorithms Q117

0. Assume that a mergesort algorithm in the worst case takes 30 seconds for an input of size 64. Which of the following most closely approximates the maximum input size of a problem that can be solved in 6 minutes?

  • Option : B
  • Explanation :
    Time complexty is O (nlogn)
    C * 64 log 64 = 30
    (C = 5/14)
    for 6 minuts
    5/64 * n log n 6 * 60 ⇒ [n = 512]
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 *