結果 : finite automata string matching algorithm time complexity