Vidyalelo
Data Structure · Q16

String Matching

Programming · Data Structure · question 16

Q16

What is the preprocessing phase in the Knuth-Morris-Pratt (KMP) algorithm used for?

A.
To find all possible matches.
B.
To sort the text.
C.
To create a partial match table.
Answer
D.
To compute hash values for patterns.

Answer: Option C

Solution

Answer: Option C
No explanation is given for this question Let's Discuss on Board