1.

What character shift tables does Boyer-Moore’s search algorithm use?(a) good-character shift tables(b) bad-character shift tables(c) next-character shift tables(d) both good and bad character shift tablesThis question was posed to me in semester exam.My enquiry is from String Matching topic in section String Matching of Data Structures & Algorithms II

Answer»

Right CHOICE is (d) both GOOD and bad character SHIFT tables

Explanation: Boyer-Moore’s SEARCH algorithm USES both good and bad character shift tables whereas quick search algorithm uses only bad character shift tables.



Discussion

No Comment Found

Related InterviewSolutions