1.

What is the time complexity of the Quick search algorithm?(a) O(n)(b) O(log n)(c) O(m+n)(d) O(mn)I have been asked this question in an online quiz.Enquiry is from String Matching topic in section String Matching of Data Structures & Algorithms II

Answer» CORRECT CHOICE is (c) O(m+n)

Easiest explanation - The time complexity of the QUICK search algorithm was FOUND to be O(m+n) and is PROVED to be faster than Boyer-Moore’s algorithm.


Discussion

No Comment Found

Related InterviewSolutions