Problem
1. Assuming that the characters in alphabet σ can be enumerated and can be used to index arrays, give an O(m+ |σ|)-time method for constructing the last function from an m-length pattern string P.
2. Compute a table representing the KMP failure function for the pattern string "cgtacgttcgt ac".